From bad9c7b7f88689133cae59d9ccae231822a2020c Mon Sep 17 00:00:00 2001 From: Mathieu Chartier Date: Sun, 14 Jun 2015 14:14:37 -0700 Subject: New experimental GC stress mode Tries to do a GC for every unique call stack (up to 16 frames). The goal is to catch moving GC bugs and lock violations without being rediculously slow. Some tests fail on 64 bits, 32 bit host doesn't work. N5 is booting. Added runtime -Xgc options: gcstress and nogcstress. Bug: 21664466 (cherry picked from commit 310008008c90fea246efd00cb99ee7ded97c5209) Change-Id: Icb8e420f2048e8ee83bcca7937563166a2638f5c --- cmdline/cmdline_types.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'cmdline') diff --git a/cmdline/cmdline_types.h b/cmdline/cmdline_types.h index f38478cdd6..2cb86a6554 100644 --- a/cmdline/cmdline_types.h +++ b/cmdline/cmdline_types.h @@ -472,6 +472,7 @@ struct XGcOption { bool verify_pre_gc_rosalloc_ = kIsDebugBuild; bool verify_pre_sweeping_rosalloc_ = false; bool verify_post_gc_rosalloc_ = false; + bool gcstress_ = false; }; template <> @@ -509,6 +510,10 @@ struct CmdlineType : CmdlineTypeParser { xgc.verify_post_gc_rosalloc_ = true; } else if (gc_option == "nopostverify_rosalloc") { xgc.verify_post_gc_rosalloc_ = false; + } else if (gc_option == "gcstress") { + xgc.gcstress_ = true; + } else if (gc_option == "nogcstress") { + xgc.gcstress_ = false; } else if ((gc_option == "precise") || (gc_option == "noprecise") || (gc_option == "verifycardtable") || -- cgit v1.2.3