comparison src/share/vm/gc_implementation/g1/g1GCPhaseTimes.cpp @ 20216:570cb6369f17

8019342: G1: High "Other" time most likely due to card redirtying Summary: Parallelize card redirtying to decrease the time it takes. Reviewed-by: brutisso
author tschatzl
date Mon, 21 Jul 2014 09:40:19 +0200
parents 78bbf4d43a14
children 2c6ef90f030a
comparison
equal deleted inserted replaced
20215:983092f35ff7 20216:570cb6369f17
171 _last_termination_times_ms(_max_gc_threads, "%.1lf"), 171 _last_termination_times_ms(_max_gc_threads, "%.1lf"),
172 _last_termination_attempts(_max_gc_threads, SIZE_FORMAT), 172 _last_termination_attempts(_max_gc_threads, SIZE_FORMAT),
173 _last_gc_worker_end_times_ms(_max_gc_threads, "%.1lf", false), 173 _last_gc_worker_end_times_ms(_max_gc_threads, "%.1lf", false),
174 _last_gc_worker_times_ms(_max_gc_threads, "%.1lf"), 174 _last_gc_worker_times_ms(_max_gc_threads, "%.1lf"),
175 _last_gc_worker_other_times_ms(_max_gc_threads, "%.1lf"), 175 _last_gc_worker_other_times_ms(_max_gc_threads, "%.1lf"),
176 _last_redirty_logged_cards_time_ms(_max_gc_threads, "%.1lf"),
177 _last_redirty_logged_cards_processed_cards(_max_gc_threads, SIZE_FORMAT),
176 _cur_string_dedup_queue_fixup_worker_times_ms(_max_gc_threads, "%.1lf"), 178 _cur_string_dedup_queue_fixup_worker_times_ms(_max_gc_threads, "%.1lf"),
177 _cur_string_dedup_table_fixup_worker_times_ms(_max_gc_threads, "%.1lf") 179 _cur_string_dedup_table_fixup_worker_times_ms(_max_gc_threads, "%.1lf")
178 { 180 {
179 assert(max_gc_threads > 0, "Must have some GC threads"); 181 assert(max_gc_threads > 0, "Must have some GC threads");
180 } 182 }
196 _last_termination_times_ms.reset(); 198 _last_termination_times_ms.reset();
197 _last_termination_attempts.reset(); 199 _last_termination_attempts.reset();
198 _last_gc_worker_end_times_ms.reset(); 200 _last_gc_worker_end_times_ms.reset();
199 _last_gc_worker_times_ms.reset(); 201 _last_gc_worker_times_ms.reset();
200 _last_gc_worker_other_times_ms.reset(); 202 _last_gc_worker_other_times_ms.reset();
203
204 _last_redirty_logged_cards_time_ms.reset();
205 _last_redirty_logged_cards_processed_cards.reset();
206
201 } 207 }
202 208
203 void G1GCPhaseTimes::note_gc_end() { 209 void G1GCPhaseTimes::note_gc_end() {
204 _last_gc_worker_start_times_ms.verify(); 210 _last_gc_worker_start_times_ms.verify();
205 _last_ext_root_scan_times_ms.verify(); 211 _last_ext_root_scan_times_ms.verify();
231 _last_gc_worker_other_times_ms.set(i, worker_other_time); 237 _last_gc_worker_other_times_ms.set(i, worker_other_time);
232 } 238 }
233 239
234 _last_gc_worker_times_ms.verify(); 240 _last_gc_worker_times_ms.verify();
235 _last_gc_worker_other_times_ms.verify(); 241 _last_gc_worker_other_times_ms.verify();
242
243 _last_redirty_logged_cards_time_ms.verify();
244 _last_redirty_logged_cards_processed_cards.verify();
236 } 245 }
237 246
238 void G1GCPhaseTimes::note_string_dedup_fixup_start() { 247 void G1GCPhaseTimes::note_string_dedup_fixup_start() {
239 _cur_string_dedup_queue_fixup_worker_times_ms.reset(); 248 _cur_string_dedup_queue_fixup_worker_times_ms.reset();
240 _cur_string_dedup_table_fixup_worker_times_ms.reset(); 249 _cur_string_dedup_table_fixup_worker_times_ms.reset();
350 _recorded_non_young_cset_choice_time_ms)); 359 _recorded_non_young_cset_choice_time_ms));
351 print_stats(2, "Ref Proc", _cur_ref_proc_time_ms); 360 print_stats(2, "Ref Proc", _cur_ref_proc_time_ms);
352 print_stats(2, "Ref Enq", _cur_ref_enq_time_ms); 361 print_stats(2, "Ref Enq", _cur_ref_enq_time_ms);
353 if (G1DeferredRSUpdate) { 362 if (G1DeferredRSUpdate) {
354 print_stats(2, "Redirty Cards", _recorded_redirty_logged_cards_time_ms); 363 print_stats(2, "Redirty Cards", _recorded_redirty_logged_cards_time_ms);
364 if (G1Log::finest()) {
365 _last_redirty_logged_cards_time_ms.print(3, "Parallel Redirty");
366 _last_redirty_logged_cards_processed_cards.print(3, "Redirtied Cards");
367 }
355 } 368 }
356 print_stats(2, "Free CSet", 369 print_stats(2, "Free CSet",
357 (_recorded_young_free_cset_time_ms + 370 (_recorded_young_free_cset_time_ms +
358 _recorded_non_young_free_cset_time_ms)); 371 _recorded_non_young_free_cset_time_ms));
359 if (G1Log::finest()) { 372 if (G1Log::finest()) {