1.1 --- a/src/share/vm/gc_implementation/g1/g1CollectorPolicy.cpp Mon Nov 28 09:49:05 2011 -0800 1.2 +++ b/src/share/vm/gc_implementation/g1/g1CollectorPolicy.cpp Thu Nov 17 12:40:15 2011 -0800 1.3 @@ -141,6 +141,7 @@ 1.4 _summary(new Summary()), 1.5 1.6 _cur_clear_ct_time_ms(0.0), 1.7 + _mark_closure_time_ms(0.0), 1.8 1.9 _cur_ref_proc_time_ms(0.0), 1.10 _cur_ref_enq_time_ms(0.0), 1.11 @@ -959,10 +960,6 @@ 1.12 assert( verify_young_ages(), "region age verification" ); 1.13 } 1.14 1.15 -void G1CollectorPolicy::record_mark_closure_time(double mark_closure_time_ms) { 1.16 - _mark_closure_time_ms = mark_closure_time_ms; 1.17 -} 1.18 - 1.19 void G1CollectorPolicy::record_concurrent_mark_init_end(double 1.20 mark_init_elapsed_time_ms) { 1.21 _during_marking = true; 1.22 @@ -1251,6 +1248,11 @@ 1.23 // current value of "other time" 1.24 other_time_ms -= _cur_clear_ct_time_ms; 1.25 1.26 + // Subtract the time spent completing marking in the collection 1.27 + // set. Note if marking is not in progress during the pause 1.28 + // the value of _mark_closure_time_ms will be zero. 1.29 + other_time_ms -= _mark_closure_time_ms; 1.30 + 1.31 // TraceGen0Time and TraceGen1Time summary info updating. 1.32 _all_pause_times_ms->add(elapsed_ms); 1.33 1.34 @@ -1407,6 +1409,9 @@ 1.35 print_stats(1, "Scan RS", scan_rs_time); 1.36 print_stats(1, "Object Copying", obj_copy_time); 1.37 } 1.38 + if (print_marking_info) { 1.39 + print_stats(1, "Complete CSet Marking", _mark_closure_time_ms); 1.40 + } 1.41 print_stats(1, "Clear CT", _cur_clear_ct_time_ms); 1.42 #ifndef PRODUCT 1.43 print_stats(1, "Cur Clear CC", _cur_clear_cc_time_ms); 1.44 @@ -1418,9 +1423,14 @@ 1.45 } 1.46 #endif 1.47 print_stats(1, "Other", other_time_ms); 1.48 - print_stats(2, "Choose CSet", _recorded_young_cset_choice_time_ms); 1.49 + print_stats(2, "Choose CSet", 1.50 + (_recorded_young_cset_choice_time_ms + 1.51 + _recorded_non_young_cset_choice_time_ms)); 1.52 print_stats(2, "Ref Proc", _cur_ref_proc_time_ms); 1.53 print_stats(2, "Ref Enq", _cur_ref_enq_time_ms); 1.54 + print_stats(2, "Free CSet", 1.55 + (_recorded_young_free_cset_time_ms + 1.56 + _recorded_non_young_free_cset_time_ms)); 1.57 1.58 for (int i = 0; i < _aux_num; ++i) { 1.59 if (_cur_aux_times_set[i]) {