summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-11-29 17:26:14 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2023-11-29 17:26:28 +0000
commitc1f8c51a3f7fb1c00314c372985b9a913bc94e03 (patch)
tree1c7ce79bde4de970a59ac64bb41a196e209f76b1
parent04ca607c0c3e5a8d0eca632faf2d9e3bf3835fd9 (diff)
parentc6f686f0da2791cad75973b1ee219942ae65f6cc (diff)
downloadart-c1f8c51a3f7fb1c00314c372985b9a913bc94e03.tar.gz
Make change and version bump to aml_art_341311040 for mainline module file: build/apex/manifest-art.json
Merge cherrypicks of ['googleplex-android-review.googlesource.com/25451144', 'googleplex-android-review.googlesource.com/25468426', 'googleplex-android-review.googlesource.com/25478576'] into sparse-11133968-L57800030000531834. SPARSE_CHANGE: Id177e767b9de95886d7b48fdf57222fdd2153ec4 SPARSE_CHANGE: Ie3ff2fa7d860c0402914884363f5517b75139387 SPARSE_CHANGE: Ic40f64c4e626610d3d03b95c79a20d151371b1ff Change-Id: I5925a05643bf337e13eaa6f6d275353d8f479983
-rw-r--r--build/apex/manifest-art.json2
-rw-r--r--profman/profile_assistant.h4
-rw-r--r--profman/profile_assistant_test.cc20
-rw-r--r--profman/profman.cc4
-rw-r--r--runtime/jit/jit.cc2
-rw-r--r--runtime/native/dalvik_system_ZygoteHooks.cc10
6 files changed, 12 insertions, 30 deletions
diff --git a/build/apex/manifest-art.json b/build/apex/manifest-art.json
index e30953f63d..7147db7525 100644
--- a/build/apex/manifest-art.json
+++ b/build/apex/manifest-art.json
@@ -3,7 +3,7 @@
// Placeholder module version to be replaced during build.
// Do not change!
- "version": 341311020,
+ "version": 341311040,
"provideNativeLibs": [
"libjdwp.so"
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 f7c4255071..d06571ef0d 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 375a489821..3ce5d699b4 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("");
diff --git a/runtime/jit/jit.cc b/runtime/jit/jit.cc
index b231cce0bc..3472c788ab 100644
--- a/runtime/jit/jit.cc
+++ b/runtime/jit/jit.cc
@@ -71,7 +71,7 @@ static constexpr uint32_t kJitStressDefaultOptimizeThreshold = kJitDefaultOptimi
static constexpr uint32_t kJitSlowStressDefaultOptimizeThreshold =
kJitStressDefaultOptimizeThreshold / 2;
-static constexpr uint32_t kJitDefaultWarmupThreshold = 0xffff;
+static constexpr uint32_t kJitDefaultWarmupThreshold = 0x3fff;
// Different warm-up threshold constants. These default to the equivalent warmup thresholds divided
// by 2, but can be overridden at the command-line.
static constexpr uint32_t kJitStressDefaultWarmupThreshold = kJitDefaultWarmupThreshold / 2;
diff --git a/runtime/native/dalvik_system_ZygoteHooks.cc b/runtime/native/dalvik_system_ZygoteHooks.cc
index 3c73cc569e..af0ee53854 100644
--- a/runtime/native/dalvik_system_ZygoteHooks.cc
+++ b/runtime/native/dalvik_system_ZygoteHooks.cc
@@ -347,10 +347,12 @@ static void ZygoteHooks_nativePostForkChild(JNIEnv* env,
runtime->GetHeap()->PostForkChildAction(thread);
- // Setup an app startup complete task in case the app doesn't notify it
- // through VMRuntime::notifyStartupCompleted.
- static constexpr uint64_t kMaxAppStartupTimeNs = MsToNs(5000); // 5 seconds
- runtime->GetHeap()->AddHeapTask(new StartupCompletedTask(NanoTime() + kMaxAppStartupTimeNs));
+ if (!is_zygote) {
+ // Setup an app startup complete task in case the app doesn't notify it
+ // through VMRuntime::notifyStartupCompleted.
+ static constexpr uint64_t kMaxAppStartupTimeNs = MsToNs(5000); // 5 seconds
+ runtime->GetHeap()->AddHeapTask(new StartupCompletedTask(NanoTime() + kMaxAppStartupTimeNs));
+ }
if (runtime->GetJit() != nullptr) {
if (!is_system_server) {