diff src/share/vm/gc_implementation/g1/g1RemSet.hpp @ 1708:a03ae377b2e8

6930581: G1: assert(ParallelGCThreads > 1 || n_yielded() == _hrrs->occupied(),"Should have yielded all the .. Summary: During RSet updating, when ParallelGCThreads is zero, references that point into the collection set are added directly the referenced region's RSet. This can cause the sparse table in the RSet to expand. RSet scanning and the "occupied" routine will then operate on different instances of the sparse table causing the assert to trip. This may also cause some cards added post expansion to be missed during RSet scanning. When ParallelGCThreads is non-zero such references are recorded on the "references to be scanned" queue and the card containing the reference is recorded in a dirty card queue for use in the event of an evacuation failure. Employ the parallel code in the serial case to avoid expanding the RSets of regions in the collection set. Reviewed-by: iveresov, ysr, tonyp
author johnc
date Fri, 06 Aug 2010 10:17:21 -0700
parents 2d160770d2e5
children c32059ef4dc0
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/g1RemSet.hpp	Wed Aug 04 13:03:23 2010 -0400
+++ b/src/share/vm/gc_implementation/g1/g1RemSet.hpp	Fri Aug 06 10:17:21 2010 -0700
@@ -148,10 +148,10 @@
   size_t*             _cards_scanned;
   size_t              _total_cards_scanned;
 
-  // _par_traversal_in_progress is "true" iff a parallel traversal is in
-  // progress.
-  bool _par_traversal_in_progress;
-  void set_par_traversal(bool b) { _par_traversal_in_progress = b; }
+  // _traversal_in_progress is "true" iff a traversal is in progress.
+
+  bool _traversal_in_progress;
+  void set_traversal(bool b) { _traversal_in_progress = b; }
 
   // Used for caching the closure that is responsible for scanning
   // references into the collection set.