RFR (S): 8049341: Parallelize clearing the next mark bitmap

Mikael Gerdin mikael.gerdin at oracle.com
Fri Aug 29 11:04:18 UTC 2014


Hi Marcus,

On 2014-08-28 13:06, Marcus Larsson wrote:
> Hi,
>
> I would like reviews for the following patch to parallelize the clearing
> of the next mark bitmap in G1.
>
> Short summary:
> The heap is divided into as many parts as there are workers and each
> worker will clear its corresponding part of the bitmap. Workers will
> join the suspendible thread set instead of the concurrent mark thread to
> properly allow them to yield during clearing work. Added support for
> applying heap region closures to a specific part of the heap.
> SPECjbb2013 shows a slight performance gain with this change (4%, using
> 4 concurrent threads).
>
> Webrev:
> http://cr.openjdk.java.net/~brutisso/webrev-8049341/

In g1Collectedheap.cpp
2624 void
2625 G1CollectedHeap::heap_region_par_iterate_chunked(HeapRegionClosure* cl,
2626                                                  uint worker_id,
2627                                                  uint num_workers,
2628                                                  jint claim_value) 
const {
2629   _hrs.par_iterate(cl, worker_id, num_workers, claim_value);
2630 }
2631
2632 void
2633 G1CollectedHeap::heap_region_iterate_range(HeapRegionClosure* cl, 
uint start, uint end) const {
2634   _hrs.iterate_range(cl, start, end);
2635 }

Can you change heap_region_par_iterate_chunked to have the return type 
on the same line as the name instead of making heap_region_iterate_range 
copy its style? All surrounding methods follow that convention.

Otherwise I think the change looks good.

/Mikael


>
> Bug:
> https://bugs.openjdk.java.net/browse/JDK-8049341
>
> Testing:
> jprt, SPECjbb2013, SPECjbb2005, SPECjvm2008
>
> Thanks,
> Marcus



More information about the hotspot-gc-dev mailing list