summaryrefslogtreecommitdiff
path: root/compiler/driver/compiler_driver.cc
diff options
context:
space:
mode:
author Nicolas Geoffray <ngeoffray@google.com> 2017-11-24 08:58:18 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2017-11-24 08:58:18 +0000
commit986005c955860a69d788f7ff7d7f28964eb684ad (patch)
tree243c70c2b0317ea52cae27d633d7e68e7aa4db05 /compiler/driver/compiler_driver.cc
parentcb88102367cda5b51753f4422f38910f054c3674 (diff)
parentb4c6acbf281c1cf960444e35bcac254a1f77c3ed (diff)
Merge "Optimize lookup of quickening data."
Diffstat (limited to 'compiler/driver/compiler_driver.cc')
-rw-r--r--compiler/driver/compiler_driver.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc
index e4dd544890..fd7ae9f570 100644
--- a/compiler/driver/compiler_driver.cc
+++ b/compiler/driver/compiler_driver.cc
@@ -429,6 +429,10 @@ static optimizer::DexToDexCompilationLevel GetDexToDexCompilationLevel(
// optimizations that could break that.
max_level = optimizer::DexToDexCompilationLevel::kDontDexToDexCompile;
}
+ if (!VdexFile::CanEncodeQuickenedData(dex_file)) {
+ // Don't do any dex level optimizations if we cannot encode the quickening.
+ return optimizer::DexToDexCompilationLevel::kDontDexToDexCompile;
+ }
if (klass->IsVerified()) {
// Class is verified so we can enable DEX-to-DEX compilation for performance.
return max_level;