diff options
-rw-r--r-- | dalvik/src/main/java/dalvik/system/ZygoteHooks.java | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/dalvik/src/main/java/dalvik/system/ZygoteHooks.java b/dalvik/src/main/java/dalvik/system/ZygoteHooks.java index f05ea2cca6..51a08acc6a 100644 --- a/dalvik/src/main/java/dalvik/system/ZygoteHooks.java +++ b/dalvik/src/main/java/dalvik/system/ZygoteHooks.java @@ -156,16 +156,11 @@ public final class ZygoteHooks { /** * Is it safe to keep all ART daemon threads stopped indefinitely in the zygote? * The answer may change from false to true dynamically, but not in the other - * direction. + * direction. Only called in Zygote. */ @libcore.api.CorePlatformApi public static boolean indefiniteThreadSuspensionOK() { - // TODO: Make this return true if we're done with JIT compilation. - // - // We only care about JIT compilation that affects other processes. - // The zygote itself doesn't run appreciable amounts of Java code when - // running single-threaded. - return !nativeZygoteJitEnabled(); + return nativeZygoteLongSuspendOk(); } // Hook for SystemServer specific early initialization post-forking. @@ -179,7 +174,7 @@ public final class ZygoteHooks { boolean isSystemServer, boolean isZygote, String instructionSet); - private static native boolean nativeZygoteJitEnabled(); + private static native boolean nativeZygoteLongSuspendOk(); /** * We must not fork until we're single-threaded again. Wait until /proc shows we're |