97 _gc_par_phases[RedirtyCards]->link_thread_work_items(_redirtied_cards);
98
99 _gc_par_phases[YoungFreeCSet] = new WorkerDataArray<double>(max_gc_threads, "Young Free Collection Set (ms):");
100 _gc_par_phases[NonYoungFreeCSet] = new WorkerDataArray<double>(max_gc_threads, "Non-Young Free Collection Set (ms):");
101
102 _gc_par_phases[PreserveCMReferents] = new WorkerDataArray<double>(max_gc_threads, "Parallel Preserve CM Refs (ms):");
103
104 reset();
105 }
106
107 void G1GCPhaseTimes::reset() {
108 _cur_collection_par_time_ms = 0.0;
109 _cur_collection_code_root_fixup_time_ms = 0.0;
110 _cur_strong_code_root_purge_time_ms = 0.0;
111 _cur_evac_fail_recalc_used = 0.0;
112 _cur_evac_fail_restore_remsets = 0.0;
113 _cur_evac_fail_remove_self_forwards = 0.0;
114 _cur_string_dedup_fixup_time_ms = 0.0;
115 _cur_prepare_tlab_time_ms = 0.0;
116 _cur_resize_tlab_time_ms = 0.0;
117 _cur_dpt_update_time_ms = 0.0;
118 _cur_clear_ct_time_ms = 0.0;
119 _cur_expand_heap_time_ms = 0.0;
120 _cur_ref_proc_time_ms = 0.0;
121 _cur_ref_enq_time_ms = 0.0;
122 _cur_collection_start_sec = 0.0;
123 _root_region_scan_wait_time_ms = 0.0;
124 _external_accounted_time_ms = 0.0;
125 _recorded_clear_claimed_marks_time_ms = 0.0;
126 _recorded_young_cset_choice_time_ms = 0.0;
127 _recorded_non_young_cset_choice_time_ms = 0.0;
128 _recorded_redirty_logged_cards_time_ms = 0.0;
129 _recorded_preserve_cm_referents_time_ms = 0.0;
130 _recorded_merge_pss_time_ms = 0.0;
131 _recorded_start_new_cset_time_ms = 0.0;
132 _recorded_total_free_cset_time_ms = 0.0;
133 _recorded_serial_free_cset_time_ms = 0.0;
134 _cur_fast_reclaim_humongous_time_ms = 0.0;
135 _cur_fast_reclaim_humongous_register_time_ms = 0.0;
136 _cur_fast_reclaim_humongous_total = 0;
137 _cur_fast_reclaim_humongous_candidates = 0;
364 debug_phase(_gc_par_phases[StringDedupQueueFixup]);
365 debug_phase(_gc_par_phases[StringDedupTableFixup]);
366 }
367
368 debug_time("Clear Card Table", _cur_clear_ct_time_ms);
369
370 if (G1CollectedHeap::heap()->evacuation_failed()) {
371 debug_time("Evacuation Failure", evac_fail_handling);
372 trace_time("Recalculate Used", _cur_evac_fail_recalc_used);
373 trace_time("Remove Self Forwards",_cur_evac_fail_remove_self_forwards);
374 trace_time("Restore RemSet", _cur_evac_fail_restore_remsets);
375 }
376
377 debug_time("Reference Enqueuing", _cur_ref_enq_time_ms);
378
379 debug_time("Merge Per-Thread State", _recorded_merge_pss_time_ms);
380 debug_time("Code Roots Purge", _cur_strong_code_root_purge_time_ms);
381
382 debug_time("Redirty Cards", _recorded_redirty_logged_cards_time_ms);
383 #if defined(COMPILER2) || INCLUDE_JVMCI
384 debug_time("DPT Update", _cur_dpt_update_time_ms);
385 #endif
386 if (_recorded_clear_claimed_marks_time_ms > 0.0) {
387 debug_time("Clear Claimed Marks", _recorded_clear_claimed_marks_time_ms);
388 }
389
390 trace_phase(_gc_par_phases[RedirtyCards]);
391
392 debug_time("Free Collection Set", _recorded_total_free_cset_time_ms);
393 trace_time("Free Collection Set Serial", _recorded_serial_free_cset_time_ms);
394 trace_phase(_gc_par_phases[YoungFreeCSet]);
395 trace_phase(_gc_par_phases[NonYoungFreeCSet]);
396
397 if (G1EagerReclaimHumongousObjects) {
398 debug_time("Humongous Reclaim", _cur_fast_reclaim_humongous_time_ms);
399 trace_count("Humongous Reclaimed", _cur_fast_reclaim_humongous_reclaimed);
400 }
401 debug_time("Start New Collection Set", _recorded_start_new_cset_time_ms);
402 if (UseTLAB && ResizeTLAB) {
403 debug_time("Resize TLABs", _cur_resize_tlab_time_ms);
404 }
|
97 _gc_par_phases[RedirtyCards]->link_thread_work_items(_redirtied_cards);
98
99 _gc_par_phases[YoungFreeCSet] = new WorkerDataArray<double>(max_gc_threads, "Young Free Collection Set (ms):");
100 _gc_par_phases[NonYoungFreeCSet] = new WorkerDataArray<double>(max_gc_threads, "Non-Young Free Collection Set (ms):");
101
102 _gc_par_phases[PreserveCMReferents] = new WorkerDataArray<double>(max_gc_threads, "Parallel Preserve CM Refs (ms):");
103
104 reset();
105 }
106
107 void G1GCPhaseTimes::reset() {
108 _cur_collection_par_time_ms = 0.0;
109 _cur_collection_code_root_fixup_time_ms = 0.0;
110 _cur_strong_code_root_purge_time_ms = 0.0;
111 _cur_evac_fail_recalc_used = 0.0;
112 _cur_evac_fail_restore_remsets = 0.0;
113 _cur_evac_fail_remove_self_forwards = 0.0;
114 _cur_string_dedup_fixup_time_ms = 0.0;
115 _cur_prepare_tlab_time_ms = 0.0;
116 _cur_resize_tlab_time_ms = 0.0;
117 _cur_derived_pointer_table_update_time_ms = 0.0;
118 _cur_clear_ct_time_ms = 0.0;
119 _cur_expand_heap_time_ms = 0.0;
120 _cur_ref_proc_time_ms = 0.0;
121 _cur_ref_enq_time_ms = 0.0;
122 _cur_collection_start_sec = 0.0;
123 _root_region_scan_wait_time_ms = 0.0;
124 _external_accounted_time_ms = 0.0;
125 _recorded_clear_claimed_marks_time_ms = 0.0;
126 _recorded_young_cset_choice_time_ms = 0.0;
127 _recorded_non_young_cset_choice_time_ms = 0.0;
128 _recorded_redirty_logged_cards_time_ms = 0.0;
129 _recorded_preserve_cm_referents_time_ms = 0.0;
130 _recorded_merge_pss_time_ms = 0.0;
131 _recorded_start_new_cset_time_ms = 0.0;
132 _recorded_total_free_cset_time_ms = 0.0;
133 _recorded_serial_free_cset_time_ms = 0.0;
134 _cur_fast_reclaim_humongous_time_ms = 0.0;
135 _cur_fast_reclaim_humongous_register_time_ms = 0.0;
136 _cur_fast_reclaim_humongous_total = 0;
137 _cur_fast_reclaim_humongous_candidates = 0;
364 debug_phase(_gc_par_phases[StringDedupQueueFixup]);
365 debug_phase(_gc_par_phases[StringDedupTableFixup]);
366 }
367
368 debug_time("Clear Card Table", _cur_clear_ct_time_ms);
369
370 if (G1CollectedHeap::heap()->evacuation_failed()) {
371 debug_time("Evacuation Failure", evac_fail_handling);
372 trace_time("Recalculate Used", _cur_evac_fail_recalc_used);
373 trace_time("Remove Self Forwards",_cur_evac_fail_remove_self_forwards);
374 trace_time("Restore RemSet", _cur_evac_fail_restore_remsets);
375 }
376
377 debug_time("Reference Enqueuing", _cur_ref_enq_time_ms);
378
379 debug_time("Merge Per-Thread State", _recorded_merge_pss_time_ms);
380 debug_time("Code Roots Purge", _cur_strong_code_root_purge_time_ms);
381
382 debug_time("Redirty Cards", _recorded_redirty_logged_cards_time_ms);
383 #if defined(COMPILER2) || INCLUDE_JVMCI
384 debug_time("DerivedPointerTable Update", _cur_derived_pointer_table_update_time_ms);
385 #endif
386 if (_recorded_clear_claimed_marks_time_ms > 0.0) {
387 debug_time("Clear Claimed Marks", _recorded_clear_claimed_marks_time_ms);
388 }
389
390 trace_phase(_gc_par_phases[RedirtyCards]);
391
392 debug_time("Free Collection Set", _recorded_total_free_cset_time_ms);
393 trace_time("Free Collection Set Serial", _recorded_serial_free_cset_time_ms);
394 trace_phase(_gc_par_phases[YoungFreeCSet]);
395 trace_phase(_gc_par_phases[NonYoungFreeCSet]);
396
397 if (G1EagerReclaimHumongousObjects) {
398 debug_time("Humongous Reclaim", _cur_fast_reclaim_humongous_time_ms);
399 trace_count("Humongous Reclaimed", _cur_fast_reclaim_humongous_reclaimed);
400 }
401 debug_time("Start New Collection Set", _recorded_start_new_cset_time_ms);
402 if (UseTLAB && ResizeTLAB) {
403 debug_time("Resize TLABs", _cur_resize_tlab_time_ms);
404 }
|