< prev index next >
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
Print this page
@@ -223,20 +223,17 @@
assert(UseCompressedClassPointers ||
junk->prev_addr() == (void*)(oop(junk)->klass_addr()),
"Offset of FreeChunk::_prev within FreeChunk must match"
" that of OopDesc::_klass within OopDesc");
)
- if (CollectedHeap::use_parallel_gc_threads()) {
+
typedef CMSParGCThreadState* CMSParGCThreadStatePtr;
- _par_gc_thread_states =
- NEW_C_HEAP_ARRAY(CMSParGCThreadStatePtr, ParallelGCThreads, mtGC);
+ _par_gc_thread_states = NEW_C_HEAP_ARRAY(CMSParGCThreadStatePtr, ParallelGCThreads, mtGC);
for (uint i = 0; i < ParallelGCThreads; i++) {
_par_gc_thread_states[i] = new CMSParGCThreadState(cmsSpace());
}
- } else {
- _par_gc_thread_states = NULL;
- }
+
_incremental_collection_failed = false;
// The "dilatation_factor" is the expansion that can occur on
// account of the fact that the minimum object size in the CMS
// generation may be larger than that in, say, a contiguous young
// generation.
@@ -2128,14 +2125,11 @@
_ct->klass_rem_set()->set_accumulate_modified_oops(true);
}
bool registerClosure = duringMarking;
- ModUnionClosure* muc = CollectedHeap::use_parallel_gc_threads() ?
- &_modUnionClosurePar
- : &_modUnionClosure;
- _cmsGen->gc_prologue_work(full, registerClosure, muc);
+ _cmsGen->gc_prologue_work(full, registerClosure, &_modUnionClosurePar);
if (!full) {
stats().record_gc0_begin();
}
}
@@ -3004,11 +2998,11 @@
print_eden_and_survivor_chunk_arrays();
}
{
COMPILER2_PRESENT(DerivedPointerTableDeactivate dpt_deact;)
- if (CMSParallelInitialMarkEnabled && CollectedHeap::use_parallel_gc_threads()) {
+ if (CMSParallelInitialMarkEnabled) {
// The parallel version.
FlexibleWorkGang* workers = gch->workers();
assert(workers != NULL, "Need parallel worker threads.");
int n_workers = workers->active_workers();
CMSParInitialMarkTask tsk(this, n_workers);
@@ -4346,11 +4340,11 @@
// A would be collected. Such updates to references in marked objects
// are detected via the mod union table which is the set of all cards
// dirtied since the first checkpoint in this GC cycle and prior to
// the most recent young generation GC, minus those cleaned up by the
// concurrent precleaning.
- if (CMSParallelRemarkEnabled && CollectedHeap::use_parallel_gc_threads()) {
+ if (CMSParallelRemarkEnabled) {
GCTraceTime t("Rescan (parallel) ", PrintGCDetails, false, _gc_timer_cm, _gc_tracer_cm->gc_id());
do_remark_parallel();
} else {
GCTraceTime t("Rescan (non-parallel) ", PrintGCDetails, false,
_gc_timer_cm, _gc_tracer_cm->gc_id());
< prev index next >