RFR(S): 7119908: G1: Cache CSet start region for each worker for subsequent reuse

John Cuthbertson john.cuthbertson at oracle.com
Tue Dec 13 18:39:48 UTC 2011

Hi Everyone,

I have a new webrev based upon comments from Tony, which can be found 
at: http://cr.openjdk.java.net/~johnc/7119908/webrev.1/

Changes in this version include:

* Using the value of the existing G1CollectedHeap::_gc_time_stamp field, 
rather than the value of _total_collections, as the TS values.
* A small optimization that may reduce the number of iterations while 
walking the collection set to calculate the starting region for a 
worker. We check the entry for the previous worker and if that is valid 
then we starting iterating over the collection set from that region.

GC test suite; jprt.



On 12/09/11 11:18, John Cuthbertson wrote:
> Hi Everyone,
> Can I have a couple of volunteers to review the changes for this CR? 
> The webrev can be found at: 
> http://cr.openjdk.java.net/~johnc/7119908/webrev.0/
> Summary:
> As part of the code review comments for 7112743 (G1: Reduce overhead 
> of marking closure during evacuation pauses) it was suggested that 
> instead of recalculating the starting heap region for each worker 
> thread, we reuse the values calculated during RSet scanning. These 
> changes address that review comment. In these changes I maintain a 
> cache that is used and updated by 
> G1CollectedHeap::start_cset_region_for_worker(). The first time this 
> routine is called by a worker thread during an evacuation pause 
> (currently during RSet scanning) the cached value for the worker gets 
> set; when the routine is called subsequently the region that was 
> cached for the worker is returned. I employ a simple stamp mechanism 
> based upon the number of GCs that ensures the validity of the regions 
> in the cache and makes clearing the cache unnecessary.
> Testing:
> GC Test suite with a small marking threshold (10%) with and without 
> verification; the configuration of SPECjbb used to test 7117423; 
> Kitchensink.
> Thanks,
> JohnC

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/hotspot-gc-dev/attachments/20111213/773d1184/attachment.htm>

More information about the hotspot-gc-dev mailing list