src/share/vm/gc_implementation/g1/g1RemSet.cpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File hs-gc-g1-logging-remove-serial Sdiff src/share/vm/gc_implementation/g1

src/share/vm/gc_implementation/g1/g1RemSet.cpp

Print this page
rev 3484 : 7178363: G1: Remove the serial code for PrintGCDetails and make it a special case of the parallel code
Summary: Introduced the WorkerDataArray class.
Reviewed-by: mgerdin


 374   // are wholly 'free' of live objects. In the event of an evacuation
 375   // failure the cards/buffers in this queue set are:
 376   // * passed to the DirtyCardQueueSet that is used to manage deferred
 377   //   RSet updates, or
 378   // * scanned for references that point into the collection set
 379   //   and the RSet of the corresponding region in the collection set
 380   //   is updated immediately.
 381   DirtyCardQueue into_cset_dcq(&_g1->into_cset_dirty_card_queue_set());
 382 
 383   assert((ParallelGCThreads > 0) || worker_i == 0, "invariant");
 384 
 385   // The two flags below were introduced temporarily to serialize
 386   // the updating and scanning of remembered sets. There are some
 387   // race conditions when these two operations are done in parallel
 388   // and they are causing failures. When we resolve said race
 389   // conditions, we'll revert back to parallel remembered set
 390   // updating and scanning. See CRs 6677707 and 6677708.
 391   if (G1UseParallelRSetUpdating || (worker_i == 0)) {
 392     updateRS(&into_cset_dcq, worker_i);
 393   } else {
 394     _g1p->phase_times()->record_update_rs_processed_buffers(worker_i, 0.0);
 395     _g1p->phase_times()->record_update_rs_time(worker_i, 0.0);
 396   }
 397   if (G1UseParallelRSetScanning || (worker_i == 0)) {
 398     scanRS(oc, worker_i);
 399   } else {
 400     _g1p->phase_times()->record_scan_rs_time(worker_i, 0.0);
 401   }
 402 
 403   // We now clear the cached values of _cset_rs_update_cl for this worker
 404   _cset_rs_update_cl[worker_i] = NULL;
 405 }
 406 
 407 void G1RemSet::prepare_for_oops_into_collection_set_do() {
 408   cleanupHRRS();
 409   ConcurrentG1Refine* cg1r = _g1->concurrent_g1_refine();
 410   _g1->set_refine_cte_cl_concurrency(false);
 411   DirtyCardQueueSet& dcqs = JavaThread::dirty_card_queue_set();
 412   dcqs.concatenate_logs();
 413 
 414   if (G1CollectedHeap::use_parallel_gc_threads()) {




 374   // are wholly 'free' of live objects. In the event of an evacuation
 375   // failure the cards/buffers in this queue set are:
 376   // * passed to the DirtyCardQueueSet that is used to manage deferred
 377   //   RSet updates, or
 378   // * scanned for references that point into the collection set
 379   //   and the RSet of the corresponding region in the collection set
 380   //   is updated immediately.
 381   DirtyCardQueue into_cset_dcq(&_g1->into_cset_dirty_card_queue_set());
 382 
 383   assert((ParallelGCThreads > 0) || worker_i == 0, "invariant");
 384 
 385   // The two flags below were introduced temporarily to serialize
 386   // the updating and scanning of remembered sets. There are some
 387   // race conditions when these two operations are done in parallel
 388   // and they are causing failures. When we resolve said race
 389   // conditions, we'll revert back to parallel remembered set
 390   // updating and scanning. See CRs 6677707 and 6677708.
 391   if (G1UseParallelRSetUpdating || (worker_i == 0)) {
 392     updateRS(&into_cset_dcq, worker_i);
 393   } else {
 394     _g1p->phase_times()->record_update_rs_processed_buffers(worker_i, 0);
 395     _g1p->phase_times()->record_update_rs_time(worker_i, 0.0);
 396   }
 397   if (G1UseParallelRSetScanning || (worker_i == 0)) {
 398     scanRS(oc, worker_i);
 399   } else {
 400     _g1p->phase_times()->record_scan_rs_time(worker_i, 0.0);
 401   }
 402 
 403   // We now clear the cached values of _cset_rs_update_cl for this worker
 404   _cset_rs_update_cl[worker_i] = NULL;
 405 }
 406 
 407 void G1RemSet::prepare_for_oops_into_collection_set_do() {
 408   cleanupHRRS();
 409   ConcurrentG1Refine* cg1r = _g1->concurrent_g1_refine();
 410   _g1->set_refine_cte_cl_concurrency(false);
 411   DirtyCardQueueSet& dcqs = JavaThread::dirty_card_queue_set();
 412   dcqs.concatenate_logs();
 413 
 414   if (G1CollectedHeap::use_parallel_gc_threads()) {


src/share/vm/gc_implementation/g1/g1RemSet.cpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File