--- old/src/share/vm/gc/g1/g1CollectedHeap.cpp 2017-05-23 13:27:45.660898493 +0200 +++ new/src/share/vm/gc/g1/g1CollectedHeap.cpp 2017-05-23 13:27:45.544894934 +0200 @@ -3273,7 +3273,7 @@ // investigate this in CR 7178365. double sample_end_time_sec = os::elapsedTime(); double pause_time_ms = (sample_end_time_sec - sample_start_time_sec) * MILLIUNITS; - size_t total_cards_scanned = per_thread_states.total_cards_scanned(); + size_t total_cards_scanned = g1_policy()->phase_times()->sum_thread_work_items(G1GCPhaseTimes::ScanRS, G1GCPhaseTimes::ScannedCards); g1_policy()->record_collection_pause_end(pause_time_ms, total_cards_scanned, heap_used_bytes_before_gc); evacuation_info.set_collectionset_used_before(collection_set()->bytes_used_before()); @@ -3463,11 +3463,9 @@ // treating the nmethods visited to act as roots for concurrent marking. // We only want to make sure that the oops in the nmethods are adjusted with regard to the // objects copied by the current evacuation. - size_t cards_scanned = _g1h->g1_rem_set()->oops_into_collection_set_do(&push_heap_rs_cl, - pss->closures()->weak_codeblobs(), - worker_id); - - _pss->add_cards_scanned(worker_id, cards_scanned); + _g1h->g1_rem_set()->oops_into_collection_set_do(&push_heap_rs_cl, + pss->closures()->weak_codeblobs(), + worker_id); double strong_roots_sec = os::elapsedTime() - start_strong_roots_sec;