Stack maps: Refactor constructors.
Create dedicated static methods instead of passing flags.
This creates dedicated methods for the purpose and merges
constructor and decoding into single optimized method.
This speeds up CodeInfo by 10%, and maps startup by 0.1%.
Test: ./art/test.py -b --host
Change-Id: Ic7d43e22bca0be9fb13bc2c7544ebfdf46798cfe
diff --git a/runtime/entrypoints/entrypoint_utils.cc b/runtime/entrypoints/entrypoint_utils.cc
index 71196d4..17be7ec 100644
--- a/runtime/entrypoints/entrypoint_utils.cc
+++ b/runtime/entrypoints/entrypoint_utils.cc
@@ -205,7 +205,7 @@
DCHECK(current_code->IsOptimized());
if (CodeInfo::HasInlineInfo(current_code->GetOptimizedCodeInfoPtr())) {
uintptr_t native_pc_offset = current_code->NativeQuickPcOffset(caller_pc);
- CodeInfo code_info(current_code, CodeInfo::DecodeFlags::InlineInfoOnly);
+ CodeInfo code_info = CodeInfo::DecodeInlineInfoOnly(current_code);
StackMap stack_map = code_info.GetStackMapForNativePcOffset(native_pc_offset);
DCHECK(stack_map.IsValid());
BitTableRange<InlineInfo> inline_infos = code_info.GetInlineInfosOf(stack_map);