summaryrefslogtreecommitdiff
path: root/compiler/optimizing/inliner.cc
diff options
context:
space:
mode:
author Nicolas Geoffray <ngeoffray@google.com> 2020-11-06 13:39:54 +0000
committer Treehugger Robot <treehugger-gerrit@google.com> 2020-11-06 15:26:27 +0000
commit8f2eb25ca40136a36a5d7002c8ca5a05723e334e (patch)
tree51778c592bdd3eb65d3fde8c21997eec30bd1e23 /compiler/optimizing/inliner.cc
parent8411c5ddb824bae1d3202a3bc2e42c77d351e916 (diff)
Remove NeedsDexCache logic from the compiler.
The compiled code and runtime stubs don't need to have direct access to the dex cache anymore. Test: test.py Change-Id: Id3aab9b10445ba2599e1a9ffd8e36506a745bfec
Diffstat (limited to 'compiler/optimizing/inliner.cc')
-rw-r--r--compiler/optimizing/inliner.cc10
1 files changed, 0 insertions, 10 deletions
diff --git a/compiler/optimizing/inliner.cc b/compiler/optimizing/inliner.cc
index 4eb671eb8d..a8bd4e5f9e 100644
--- a/compiler/optimizing/inliner.cc
+++ b/compiler/optimizing/inliner.cc
@@ -1823,8 +1823,6 @@ bool HInliner::CanInlineBody(const HGraph* callee_graph,
const DexFile& callee_dex_file = callee_graph->GetDexFile();
ArtMethod* const resolved_method = callee_graph->GetArtMethod();
const uint32_t method_index = resolved_method->GetMethodIndex();
- const bool same_dex_file =
- IsSameDexFile(*outer_compilation_unit_.GetDexFile(), *resolved_method->GetDexFile());
HBasicBlock* exit_block = callee_graph->GetExitBlock();
if (exit_block == nullptr) {
@@ -1925,14 +1923,6 @@ bool HInliner::CanInlineBody(const HGraph* callee_graph,
return false;
}
- if (!same_dex_file && current->NeedsDexCacheOfDeclaringClass()) {
- LOG_FAIL(stats_, MethodCompilationStat::kNotInlinedDexCache)
- << "Method " << callee_dex_file.PrettyMethod(method_index)
- << " could not be inlined because " << current->DebugName()
- << " it is in a different dex file and requires access to the dex cache";
- return false;
- }
-
if (current->IsUnresolvedStaticFieldGet() ||
current->IsUnresolvedInstanceFieldGet() ||
current->IsUnresolvedStaticFieldSet() ||