Mercurial > hg > truffle
comparison src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp @ 457:27a80744a83b
6778647: snap(), snap_policy() should be renamed setup(), setup_policy()
Summary: Renamed Reference{Policy,Pocessor} methods from snap{,_policy}() to setup{,_policy}()
Reviewed-by: apetrusenko
author | ysr |
---|---|
date | Mon, 01 Dec 2008 23:25:24 -0800 |
parents | c96030fff130 |
children | e9be0e04635a |
comparison
equal
deleted
inserted
replaced
455:434912c745cf | 457:27a80744a83b |
---|---|
1959 // Temporarily make refs discovery atomic | 1959 // Temporarily make refs discovery atomic |
1960 ReferenceProcessorAtomicMutator w(ref_processor(), true); | 1960 ReferenceProcessorAtomicMutator w(ref_processor(), true); |
1961 | 1961 |
1962 ref_processor()->set_enqueuing_is_done(false); | 1962 ref_processor()->set_enqueuing_is_done(false); |
1963 ref_processor()->enable_discovery(); | 1963 ref_processor()->enable_discovery(); |
1964 ref_processor()->snap_policy(clear_all_soft_refs); | 1964 ref_processor()->setup_policy(clear_all_soft_refs); |
1965 // If an asynchronous collection finishes, the _modUnionTable is | 1965 // If an asynchronous collection finishes, the _modUnionTable is |
1966 // all clear. If we are assuming the collection from an asynchronous | 1966 // all clear. If we are assuming the collection from an asynchronous |
1967 // collection, clear the _modUnionTable. | 1967 // collection, clear the _modUnionTable. |
1968 assert(_collectorState != Idling || _modUnionTable.isAllClear(), | 1968 assert(_collectorState != Idling || _modUnionTable.isAllClear(), |
1969 "_modUnionTable should be clear if the baton was not passed"); | 1969 "_modUnionTable should be clear if the baton was not passed"); |
2384 GenCollectedHeap::heap()->total_collections() >= VerifyGCStartAt) { | 2384 GenCollectedHeap::heap()->total_collections() >= VerifyGCStartAt) { |
2385 Universe::verify(true); | 2385 Universe::verify(true); |
2386 } | 2386 } |
2387 | 2387 |
2388 // Snapshot the soft reference policy to be used in this collection cycle. | 2388 // Snapshot the soft reference policy to be used in this collection cycle. |
2389 ref_processor()->snap_policy(clear_all_soft_refs); | 2389 ref_processor()->setup_policy(clear_all_soft_refs); |
2390 | 2390 |
2391 bool init_mark_was_synchronous = false; // until proven otherwise | 2391 bool init_mark_was_synchronous = false; // until proven otherwise |
2392 while (_collectorState != Idling) { | 2392 while (_collectorState != Idling) { |
2393 if (TraceCMSState) { | 2393 if (TraceCMSState) { |
2394 gclog_or_tty->print_cr("Thread " INTPTR_FORMAT " in CMS state %d", | 2394 gclog_or_tty->print_cr("Thread " INTPTR_FORMAT " in CMS state %d", |
5681 | 5681 |
5682 ReferenceProcessor* rp = ref_processor(); | 5682 ReferenceProcessor* rp = ref_processor(); |
5683 assert(rp->span().equals(_span), "Spans should be equal"); | 5683 assert(rp->span().equals(_span), "Spans should be equal"); |
5684 assert(!rp->enqueuing_is_done(), "Enqueuing should not be complete"); | 5684 assert(!rp->enqueuing_is_done(), "Enqueuing should not be complete"); |
5685 // Process weak references. | 5685 // Process weak references. |
5686 rp->snap_policy(clear_all_soft_refs); | 5686 rp->setup_policy(clear_all_soft_refs); |
5687 verify_work_stacks_empty(); | 5687 verify_work_stacks_empty(); |
5688 | 5688 |
5689 CMSKeepAliveClosure cmsKeepAliveClosure(this, _span, &_markBitMap, | 5689 CMSKeepAliveClosure cmsKeepAliveClosure(this, _span, &_markBitMap, |
5690 &_markStack, false /* !preclean */); | 5690 &_markStack, false /* !preclean */); |
5691 CMSDrainMarkingStackClosure cmsDrainMarkingStackClosure(this, | 5691 CMSDrainMarkingStackClosure cmsDrainMarkingStackClosure(this, |