diff options
| author | 2023-11-20 16:24:50 +0000 | |
|---|---|---|
| committer | 2023-11-20 17:25:54 +0000 | |
| commit | a35b38f23fb0e1057c38d63eccc6c4c2c6331e0e (patch) | |
| tree | 2ef416363ad795569dad2bb7120cfff2f488ed43 | |
| parent | ca176cdbc8daeab1db99d96d13f790cdf5fb57be (diff) | |
Revert "profman: Change the default new min methods/classes percent change"
This reverts commit 02f1b03d3c764dadf14ac4c6c8bca0dee6554eb8.
Reason for revert: b/242170869
Bug: 242170869
Test: Presubmit
Change-Id: Ic40f64c4e626610d3d03b95c79a20d151371b1ff
| -rw-r--r-- | profman/profile_assistant.h | 4 | ||||
| -rw-r--r-- | profman/profile_assistant_test.cc | 20 | ||||
| -rw-r--r-- | profman/profman.cc | 4 |
3 files changed, 4 insertions, 24 deletions
diff --git a/profman/profile_assistant.h b/profman/profile_assistant.h index 6b7a7a67f5..84f140f23e 100644 --- a/profman/profile_assistant.h +++ b/profman/profile_assistant.h @@ -32,8 +32,8 @@ class ProfileAssistant { public: static constexpr bool kForceMergeDefault = false; static constexpr bool kBootImageMergeDefault = false; - static constexpr uint32_t kMinNewMethodsPercentChangeForCompilation = 20; - static constexpr uint32_t kMinNewClassesPercentChangeForCompilation = 20; + static constexpr uint32_t kMinNewMethodsPercentChangeForCompilation = 2; + static constexpr uint32_t kMinNewClassesPercentChangeForCompilation = 2; Options() : force_merge_(kForceMergeDefault), diff --git a/profman/profile_assistant_test.cc b/profman/profile_assistant_test.cc index d28ec6513d..7d0868f7db 100644 --- a/profman/profile_assistant_test.cc +++ b/profman/profile_assistant_test.cc @@ -684,16 +684,6 @@ TEST_F(ProfileAssistantTest, ShouldAdviseCompilationMethodPercentage) { kNumberOfMethodsInCurProfile, kNumberOfMethodsInRefProfile, extra_args)); } -TEST_F(ProfileAssistantTest, DoNotAdviseCompilationMethodPercentageWithNewMin) { - const uint16_t kNumberOfMethodsInRefProfile = 6000; - const uint16_t kNumberOfMethodsInCurProfile = 6200; // Threshold is 20%. - - // We should not advise compilation. - ASSERT_EQ(ProfmanResult::kSkipCompilationSmallDelta, - CheckCompilationMethodPercentChange(kNumberOfMethodsInCurProfile, - kNumberOfMethodsInRefProfile)); -} - TEST_F(ProfileAssistantTest, DoNotAdviseCompilationClassPercentage) { const uint16_t kNumberOfClassesInRefProfile = 6000; const uint16_t kNumberOfClassesInCurProfile = 6110; // Threshold is 2%. @@ -716,16 +706,6 @@ TEST_F(ProfileAssistantTest, ShouldAdviseCompilationClassPercentage) { kNumberOfClassesInCurProfile, kNumberOfClassesInRefProfile, extra_args)); } -TEST_F(ProfileAssistantTest, DoNotAdviseCompilationClassPercentageWithNewMin) { - const uint16_t kNumberOfClassesInRefProfile = 6000; - const uint16_t kNumberOfClassesInCurProfile = 6200; // Threshold is 20%. - - // We should not advise compilation. - ASSERT_EQ(ProfmanResult::kSkipCompilationSmallDelta, - CheckCompilationClassPercentChange(kNumberOfClassesInCurProfile, - kNumberOfClassesInRefProfile)); -} - TEST_F(ProfileAssistantTest, FailProcessingBecauseOfProfiles) { ScratchFile profile1; ScratchFile profile2; diff --git a/profman/profman.cc b/profman/profman.cc index a359d615ab..a39d6c5981 100644 --- a/profman/profman.cc +++ b/profman/profman.cc @@ -191,9 +191,9 @@ NO_RETURN static void Usage(const char *fmt, ...) { UsageError(" In this case, the reference profile must have a boot profile version."); UsageError(" --force-merge: performs a forced merge, without analyzing if there is a"); UsageError(" significant difference between the current profile and the reference profile."); - UsageError(" --min-new-methods-percent-change=percentage between 0 and 100 (default 20)"); + UsageError(" --min-new-methods-percent-change=percentage between 0 and 100 (default 2)"); UsageError(" the min percent of new methods to trigger a compilation."); - UsageError(" --min-new-classes-percent-change=percentage between 0 and 100 (default 20)"); + UsageError(" --min-new-classes-percent-change=percentage between 0 and 100 (default 2)"); UsageError(" the min percent of new classes to trigger a compilation."); UsageError(""); |