diff options
Diffstat (limited to 'compiler/optimizing/profiling_info_builder.cc')
-rw-r--r-- | compiler/optimizing/profiling_info_builder.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/compiler/optimizing/profiling_info_builder.cc b/compiler/optimizing/profiling_info_builder.cc index 905d8d0f2f..7faf2bf5be 100644 --- a/compiler/optimizing/profiling_info_builder.cc +++ b/compiler/optimizing/profiling_info_builder.cc @@ -28,6 +28,7 @@ namespace art HIDDEN { void ProfilingInfoBuilder::Run() { + DCHECK(GetGraph()->IsUsefulOptimizing()); DCHECK_EQ(GetGraph()->GetProfilingInfo(), nullptr); // Order does not matter. for (HBasicBlock* block : GetGraph()->GetReversePostOrder()) { @@ -119,6 +120,12 @@ bool ProfilingInfoBuilder::IsInlineCacheUseful(HInvoke* invoke, CodeGenerator* c return false; } } + + if (!codegen->GetGraph()->IsUsefulOptimizing()) { + // Earlier pass knew what the calling target was. No need for an inline + // cache. + return false; + } return true; } |