Mercurial > hg > graal-compiler
diff src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.hpp @ 143:b5489bb705c9
6662086: 6u4+, 7b11+: CMS never clears referents when -XX:+ParallelRefProcEnabled
Summary: Construct the relevant CMSIsAliveClosure used by CMS during parallel reference processing with the correct span. It had incorrectly been constructed with an empty span, a regression introduced in 6417901.
Reviewed-by: jcoomes
author | ysr |
---|---|
date | Tue, 06 May 2008 15:37:36 -0700 |
parents | ba764ed4b6f2 |
children | d1605aabd0a1 37f87013dfd8 |
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.hpp Sun May 04 03:29:31 2008 -0700 +++ b/src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.hpp Tue May 06 15:37:36 2008 -0700 @@ -435,23 +435,22 @@ // if the object is "live" (reachable). Used in weak // reference processing. class CMSIsAliveClosure: public BoolObjectClosure { - MemRegion _span; + const MemRegion _span; const CMSBitMap* _bit_map; friend class CMSCollector; - protected: - void set_span(MemRegion span) { _span = span; } public: - CMSIsAliveClosure(CMSBitMap* bit_map): - _bit_map(bit_map) { } - CMSIsAliveClosure(MemRegion span, CMSBitMap* bit_map): _span(span), - _bit_map(bit_map) { } + _bit_map(bit_map) { + assert(!span.is_empty(), "Empty span could spell trouble"); + } + void do_object(oop obj) { assert(false, "not to be invoked"); } + bool do_object_b(oop obj); }; @@ -600,7 +599,7 @@ // ("Weak") Reference processing support ReferenceProcessor* _ref_processor; CMSIsAliveClosure _is_alive_closure; - // keep this textually after _markBitMap; c'tor dependency + // keep this textually after _markBitMap and _span; c'tor dependency ConcurrentMarkSweepThread* _cmsThread; // the thread doing the work ModUnionClosure _modUnionClosure;