From 6ee06e97cef5ee92944deaeba0da4d10c4c33a2a Mon Sep 17 00:00:00 2001 From: David Srbecky Date: Wed, 25 Jul 2018 21:45:54 +0100 Subject: Decode only the needed tables from CodeInfo. Most use cases need only the first two bit tables from CodeInfo. Add flag to the decode method so that only those two are loaded. We only touched the table header but that still made difference. This speeds up pmd by over 10%. Test: test-art-host-gtest Change-Id: I7740081bf18205dd69864503b5bcec7de5e1a901 --- runtime/stack.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runtime/stack.cc') diff --git a/runtime/stack.cc b/runtime/stack.cc index c4851e148b..85b1ea0524 100644 --- a/runtime/stack.cc +++ b/runtime/stack.cc @@ -795,7 +795,7 @@ void StackVisitor::WalkStack(bool include_transitions) { // JNI methods cannot have any inlined frames. && !method->IsNative()) { DCHECK_NE(cur_quick_frame_pc_, 0u); - CodeInfo code_info(cur_oat_quick_method_header_); + CodeInfo code_info(cur_oat_quick_method_header_, CodeInfo::DecodeFlags::InlineInfoOnly); uint32_t native_pc_offset = cur_oat_quick_method_header_->NativeQuickPcOffset(cur_quick_frame_pc_); StackMap stack_map = code_info.GetStackMapForNativePcOffset(native_pc_offset); -- cgit v1.2.3-59-g8ed1b