Enable / disable CMS runtime options.
Enable or disable CMS by doing -Xgc:noconcurrent or Xgc:concurrent. Defaults to enabled.
Change-Id: Ib18687ba6aa6534323531d761133ce410c69f426
diff --git a/src/runtime.h b/src/runtime.h
index 9181f1f..698f0c5 100644
--- a/src/runtime.h
+++ b/src/runtime.h
@@ -70,6 +70,7 @@
std::string jni_trace_;
bool is_compiler_;
bool is_zygote_;
+ bool is_concurrent_gc_enabled_;
size_t heap_initial_size_;
size_t heap_maximum_size_;
size_t heap_growth_limit_;
@@ -101,6 +102,10 @@
return is_zygote_;
}
+ bool IsConcurrentGcEnabled() const {
+ return is_concurrent_gc_enabled_;
+ }
+
const std::string& GetHostPrefix() const {
DCHECK(!IsStarted());
return host_prefix_;
@@ -329,6 +334,7 @@
bool is_compiler_;
bool is_zygote_;
+ bool is_concurrent_gc_enabled_;
// The host prefix is used during cross compilation. It is removed
// from the start of host paths such as: