From 3a10cc5c11cfc967d9fd04f8783e35287fdb6bfb Mon Sep 17 00:00:00 2001 From: Jagadeesh Pakaravoor Date: Thu, 18 Mar 2021 15:21:41 -0700 Subject: [PATCH] Update size limit for madvising odex, vdex files Update the size limit for madvising (MADV_WILLNEED) odex and vdex files to 100MB. Art file continues to be madvised fully, with a UINT_MAX limit. Test: presubmit Bug: 178853586 Change-Id: Ie46a0658bf30a6a9908ab30b28ce097e434e7e2d --- target/product/runtime_libart.mk | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/target/product/runtime_libart.mk b/target/product/runtime_libart.mk index 7092031de..4f14ddd40 100644 --- a/target/product/runtime_libart.mk +++ b/target/product/runtime_libart.mk @@ -142,8 +142,10 @@ PRODUCT_SYSTEM_PROPERTIES += \ # Enable Madvising of the whole art, odex and vdex files to MADV_WILLNEED. # The size specified here is the size limit of how much of the file -# (in bytes) is madvised. Setting it to UINT_MAX. +# (in bytes) is madvised. +# We madvise the whole .art file to MADV_WILLNEED with UINT_MAX limit. +# For odex and vdex files, we limit madvising to 100MB. PRODUCT_SYSTEM_PROPERTIES += \ - dalvik.vm.madvise.vdexfile.size=4294967295 \ - dalvik.vm.madvise.odexfile.size=4294967295 \ + dalvik.vm.madvise.vdexfile.size=104857600 \ + dalvik.vm.madvise.odexfile.size=104857600 \ dalvik.vm.madvise.artfile.size=4294967295