--- old/src/share/vm/gc_implementation/concurrentMarkSweep/cmsOopClosures.hpp Fri Nov 14 16:43:37 2008 +++ new/src/share/vm/gc_implementation/concurrentMarkSweep/cmsOopClosures.hpp Fri Nov 14 16:43:36 2008 @@ -325,22 +325,28 @@ // For objects in CMS generation, this closure marks // given objects (transitively) as being reachable/live. // This is currently used during the (weak) reference object -// processing phase of the CMS final checkpoint step. +// processing phase of the CMS final checkpoint step, as +// well as during the concurrent precleaning of the discovered +// reference lists. class CMSKeepAliveClosure: public OopClosure { + friend class CMSDrainMarkingStackClosure; // for assertion checking private: CMSCollector* _collector; const MemRegion _span; CMSMarkStack* _mark_stack; CMSBitMap* _bit_map; + bool _concurrent_precleaning; protected: DO_OOP_WORK_DEFN public: CMSKeepAliveClosure(CMSCollector* collector, MemRegion span, - CMSBitMap* bit_map, CMSMarkStack* mark_stack): + CMSBitMap* bit_map, CMSMarkStack* mark_stack, + bool concurrent_precleaning): _collector(collector), _span(span), _bit_map(bit_map), - _mark_stack(mark_stack) { + _mark_stack(mark_stack), + _concurrent_precleaning(concurrent_precleaning) { assert(!_span.is_empty(), "Empty span could spell trouble"); } virtual void do_oop(oop* p);