summaryrefslogtreecommitdiff
path: root/compiler
diff options
context:
space:
mode:
Diffstat (limited to 'compiler')
-rw-r--r--compiler/driver/compiler_driver.cc2
-rw-r--r--compiler/driver/compiler_driver_test.cc12
2 files changed, 5 insertions, 9 deletions
diff --git a/compiler/driver/compiler_driver.cc b/compiler/driver/compiler_driver.cc
index 91b58e1590..51446d4b35 100644
--- a/compiler/driver/compiler_driver.cc
+++ b/compiler/driver/compiler_driver.cc
@@ -1002,7 +1002,7 @@ bool CompilerDriver::ShouldCompileBasedOnProfile(const MethodReference& method_r
}
// Compile only hot methods, it is the profile saver's job to decide what startup methods to mark
// as hot.
- bool result = profile_compilation_info_->ContainsHotMethod(method_ref);
+ bool result = profile_compilation_info_->GetMethodHotness(method_ref).IsHot();
if (kDebugProfileGuidedCompilation) {
LOG(INFO) << "[ProfileGuidedCompilation] "
diff --git a/compiler/driver/compiler_driver_test.cc b/compiler/driver/compiler_driver_test.cc
index 4b979d8125..85d8b120d3 100644
--- a/compiler/driver/compiler_driver_test.cc
+++ b/compiler/driver/compiler_driver_test.cc
@@ -239,14 +239,10 @@ class CompilerDriverProfileTest : public CompilerDriverTest {
ProfileCompilationInfo info;
for (const std::unique_ptr<const DexFile>& dex_file : dex_files) {
- profile_info_.AddMethodIndex(dex_file->GetLocation(),
- dex_file->GetLocationChecksum(),
- 1,
- dex_file->NumMethodIds());
- profile_info_.AddMethodIndex(dex_file->GetLocation(),
- dex_file->GetLocationChecksum(),
- 2,
- dex_file->NumMethodIds());
+ profile_info_.AddMethodIndex(ProfileCompilationInfo::MethodHotness::kFlagHot,
+ MethodReference(dex_file.get(), 1));
+ profile_info_.AddMethodIndex(ProfileCompilationInfo::MethodHotness::kFlagHot,
+ MethodReference(dex_file.get(), 2));
}
return &profile_info_;
}