Merge "Update JIT Zygote image option." am: 6c8544e068

Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1931584

Change-Id: Id5ff8dbdcc06c2312b731981d1386f2395769925
This commit is contained in:
Treehugger Robot
2021-12-24 16:04:44 +00:00
committed by Automerger Merge Worker

View File

@@ -228,8 +228,7 @@ static const char* PROFILE_BOOT_CLASS_PATH = "profilebootclasspath";
// TODO: Rename the server-level flag or remove.
static const char* ENABLE_JITZYGOTE_IMAGE = "enable_apex_image";
// Flag to pass to the runtime when using the JIT Zygote image.
static const char* kJitZygoteImageOption =
"-Ximage:boot.art:/nonx/boot-framework.art!/system/etc/boot-image.prof";
static const char* kJitZygoteImageOption = "-Xforcejitzygote";
// Feature flag name for disabling lock profiling.
static const char* DISABLE_LOCK_PROFILING = "disable_lock_profiling";
@@ -983,9 +982,9 @@ int AndroidRuntime::startVm(JavaVM** pJavaVM, JNIEnv** pEnv, bool zygote, bool p
"--instruction-set-features=", "-Xcompiler-option");
/*
* When running with debug.generate-debug-info, add --generate-debug-info to
* the compiler options so that both JITted code and the boot image extension,
* if it is compiled on device, will include native debugging information.
* When running with debug.generate-debug-info, add --generate-debug-info to the compiler
* options so that both JITted code and the boot image, if it is compiled on device, will
* include native debugging information.
*/
property_get("debug.generate-debug-info", propBuf, "");
bool generate_debug_info = (strcmp(propBuf, "true") == 0);
@@ -1008,7 +1007,7 @@ int AndroidRuntime::startVm(JavaVM** pJavaVM, JNIEnv** pEnv, bool zygote, bool p
property_get("dalvik.vm.extra-opts", extraOptsBuf, "");
parseExtraOpts(extraOptsBuf, NULL);
// Extra options for boot image extension generation.
// Extra options for boot image generation.
if (skip_compilation) {
addOption("-Xnoimage-dex2oat");
} else {
@@ -1031,8 +1030,8 @@ int AndroidRuntime::startVm(JavaVM** pJavaVM, JNIEnv** pEnv, bool zygote, bool p
parseCompilerOption("dalvik.vm.image-dex2oat-cpu-set", dex2oatCpuSetImageBuf, "--cpu-set=",
"-Ximage-compiler-option");
// The runtime may compile a boot image extension, when necessary, not using installd.
// Thus, we need to pass the instruction-set-features/variant as an image-compiler-option.
// The runtime may compile a boot image, when necessary, not using installd. Thus, we need
// to pass the instruction-set-features/variant as an image-compiler-option.
// Note: it is OK to reuse the buffer, as the values are exactly the same between
// * compiler-option, used for runtime compilation (DexClassLoader)
// * image-compiler-option, used for boot-image compilation on device