comparison src/share/vm/gc_implementation/parallelScavenge/psParallelCompact.cpp @ 3979:4dfb2df418f2

6484982: G1: process references during evacuation pauses Summary: G1 now uses two reference processors - one is used by concurrent marking and the other is used by STW GCs (both full and incremental evacuation pauses). In an evacuation pause, the reference processor is embedded into the closures used to scan objects. Doing so causes causes reference objects to be 'discovered' by the reference processor. At the end of the evacuation pause, these discovered reference objects are processed - preserving (and copying) referent objects (and their reachable graphs) as appropriate. Reviewed-by: ysr, jwilhelm, brutisso, stefank, tonyp
author johnc
date Thu, 22 Sep 2011 10:57:37 -0700
parents c2bf0120ee5d
children bca17e38de00
comparison
equal deleted inserted replaced
3978:f0ecbe78fc7b 3979:4dfb2df418f2
2067 // When collecting the permanent generation methodOops may be moving, 2067 // When collecting the permanent generation methodOops may be moving,
2068 // so we either have to flush all bcp data or convert it into bci. 2068 // so we either have to flush all bcp data or convert it into bci.
2069 CodeCache::gc_prologue(); 2069 CodeCache::gc_prologue();
2070 Threads::gc_prologue(); 2070 Threads::gc_prologue();
2071 2071
2072 NOT_PRODUCT(ref_processor()->verify_no_references_recorded());
2073 COMPILER2_PRESENT(DerivedPointerTable::clear()); 2072 COMPILER2_PRESENT(DerivedPointerTable::clear());
2074 2073
2075 ref_processor()->enable_discovery(); 2074 ref_processor()->enable_discovery(true /*verify_disabled*/, true /*verify_no_refs*/);
2076 ref_processor()->setup_policy(maximum_heap_compaction); 2075 ref_processor()->setup_policy(maximum_heap_compaction);
2077 2076
2078 bool marked_for_unloading = false; 2077 bool marked_for_unloading = false;
2079 2078
2080 marking_start.update(); 2079 marking_start.update();