Add -XX:MadviseRandomAccess option
If enabled, ART will advise random access to the kernel for files
that are thought to have such access patterns.
Bug: 67772594
Test: verify that -XX:MadviseRandomAccess:true is passed to runtime init
(cherry picked from commit 087f2046dfdf41646c740a05004b4d40cbd99b11)
Change-Id: I76a5f62846d563a4f2cf25e47dbd320464aee8c1
diff --git a/runtime/runtime_options.def b/runtime/runtime_options.def
index cafae22..2e03562 100644
--- a/runtime/runtime_options.def
+++ b/runtime/runtime_options.def
@@ -70,6 +70,7 @@
RUNTIME_OPTIONS_KEY (bool, EnableHSpaceCompactForOOM, true)
RUNTIME_OPTIONS_KEY (bool, UseJitCompilation, false)
RUNTIME_OPTIONS_KEY (bool, DumpNativeStackOnSigQuit, true)
+RUNTIME_OPTIONS_KEY (bool, MadviseRandomAccess, false)
RUNTIME_OPTIONS_KEY (unsigned int, JITCompileThreshold)
RUNTIME_OPTIONS_KEY (unsigned int, JITWarmupThreshold)
RUNTIME_OPTIONS_KEY (unsigned int, JITOsrThreshold)