summaryrefslogtreecommitdiff
path: root/compiler/driver/compiler_driver_test.cc
diff options
context:
space:
mode:
authorMathieu Chartier <mathieuc@google.com>2017-06-13 16:36:17 -0700
committerMathieu Chartier <mathieuc@google.com>2017-06-15 11:45:06 -0700
commitbbe3a5efcdfb2fb15a4e5f724cc323ae0ada5111 (patch)
tree65fd149e1159674681d866e47e485d85b8464334 /compiler/driver/compiler_driver_test.cc
parentd58932f98a673c9d687863a7efafb2da168063a2 (diff)
Refactor some profiling info functions
Deleted profile_compilation_info-inl.h Added a new helper class MethodHotness to reduce the number of required getters for reading method hotness, startup, and post startup booleans. Test: test-art-host Bug: 62040831 Change-Id: I799a38e2bea6177ba5816c54524f4ccacedba772
Diffstat (limited to 'compiler/driver/compiler_driver_test.cc')
-rw-r--r--compiler/driver/compiler_driver_test.cc12
1 files changed, 4 insertions, 8 deletions
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_;
}