Merge "Rename profileSystemServer to shouldProfileSystemServer"
am: f7335ffb9a
Change-Id: I56fb79a947c2dc2a0c53c87472cd101674d889d9
This commit is contained in:
@@ -460,7 +460,7 @@ public class ZygoteInit {
|
|||||||
ZygoteHooks.gcAndFinalize();
|
ZygoteHooks.gcAndFinalize();
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean profileSystemServer() {
|
private static boolean shouldProfileSystemServer() {
|
||||||
boolean defaultValue = SystemProperties.getBoolean("dalvik.vm.profilesystemserver",
|
boolean defaultValue = SystemProperties.getBoolean("dalvik.vm.profilesystemserver",
|
||||||
/*default=*/ false);
|
/*default=*/ false);
|
||||||
// Can't use DeviceConfig since it's not initialized at this point.
|
// Can't use DeviceConfig since it's not initialized at this point.
|
||||||
@@ -492,7 +492,7 @@ public class ZygoteInit {
|
|||||||
}
|
}
|
||||||
// Capturing profiles is only supported for debug or eng builds since selinux normally
|
// Capturing profiles is only supported for debug or eng builds since selinux normally
|
||||||
// prevents it.
|
// prevents it.
|
||||||
if (profileSystemServer() && (Build.IS_USERDEBUG || Build.IS_ENG)) {
|
if (shouldProfileSystemServer() && (Build.IS_USERDEBUG || Build.IS_ENG)) {
|
||||||
try {
|
try {
|
||||||
Log.d(TAG, "Preparing system server profile");
|
Log.d(TAG, "Preparing system server profile");
|
||||||
prepareSystemServerProfile(systemServerClasspath);
|
prepareSystemServerProfile(systemServerClasspath);
|
||||||
@@ -765,8 +765,7 @@ public class ZygoteInit {
|
|||||||
Zygote.applyDebuggerSystemProperty(parsedArgs);
|
Zygote.applyDebuggerSystemProperty(parsedArgs);
|
||||||
Zygote.applyInvokeWithSystemProperty(parsedArgs);
|
Zygote.applyInvokeWithSystemProperty(parsedArgs);
|
||||||
|
|
||||||
if (profileSystemServer()) {
|
if (shouldProfileSystemServer()) {
|
||||||
|
|
||||||
parsedArgs.mRuntimeFlags |= Zygote.PROFILE_SYSTEM_SERVER;
|
parsedArgs.mRuntimeFlags |= Zygote.PROFILE_SYSTEM_SERVER;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user