RFR (M): 8022800: Use specific generations rather than generation iteration

Bengt Rutisson bengt.rutisson at oracle.com
Mon Aug 12 13:34:20 UTC 2013

Hi everyone,

Could I have a couple of reviews of this change?


The interesting change is in genCollectedHeap.hpp, where I change the 
methods prev_gen(), next_gen() and get_gen() to never return NULL. The 
rest of the changes are ripple effects of this change.

 From the CR:

The generations abstraction in the GC code was intended to be very 
general. In practice we now always have exactly two generations - the 
young and the old. This means that the GC code can be simplified quite a 

A first step is to change from iteration over generations to explicitly 
specify which generation is needed. This makes the code easier to follow 
and it also helps tools like Parfait to understand the code better.

This bug targets some simple clean-ups. A natural follow up of this is 
probably to change the name of GenCollectedHeap to 
TwoGenerationCollectedHeap (similar to the existing 
TwoGenerationCollectorPolicy). But that will be handled separately.

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

More information about the hotspot-gc-dev mailing list