Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b26a651b authored by Dianne Hackborn's avatar Dianne Hackborn Committed by Android (Google) Code Review
Browse files

Merge "Hook up large heap API." into honeycomb

parents 9dd9d021 de398515
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -89,6 +89,7 @@ $(call add-clean-step, rm -rf $(OUT_DIR)/target/target/common/obj/APPS/Music2_in
$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework_intermediates/src/core/java/android/nfc/INdefTag.java)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/STATIC_LIBRARIES/libstagefright_aacdec_intermediates)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/obj/STATIC_LIBRARIES/libstagefright_mp3dec_intermediates)
$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/build.prop)

# ************************************************
# NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST
+2 −1
Original line number Diff line number Diff line
@@ -19,4 +19,5 @@

PRODUCT_PROPERTY_OVERRIDES += \
    dalvik.vm.heapstartsize=5m \
    dalvik.vm.heapsize=32m
    dalvik.vm.growthlimit=32m \
    dalvik.vm.heapsize=128m
+5 −2
Original line number Diff line number Diff line
@@ -64,9 +64,12 @@ public class ActivityManager {
    static public int staticGetMemoryClass() {
        // Really brain dead right now -- just take this from the configured
        // vm heap size, and assume it is in megabytes and thus ends with "m".
        String vmHeapSize = SystemProperties.get("dalvik.vm.smallheapsize", "16m");
        String vmHeapSize = SystemProperties.get("dalvik.vm.growthlimit", "");
        if (vmHeapSize != null && !"".equals(vmHeapSize)) {
            return Integer.parseInt(vmHeapSize.substring(0, vmHeapSize.length()-1));
        }
        return staticGetLargeMemoryClass();
    }
    
    /**
     * Return the approximate per-application memory class of the current
+1 −1
Original line number Diff line number Diff line
@@ -3463,7 +3463,7 @@ public final class ActivityThread {
        }

        if ((data.appInfo.flags&ApplicationInfo.FLAG_LARGE_HEAP) != 0) {
            // XXX bump up Dalvik's heap.
            dalvik.system.VMRuntime.getRuntime().clearGrowthLimit();
        }

        // If the app is being launched for full backup or restore, bring it up in