RFR: JDK-8148733: G1: Add log message to print the heap region size

Bengt Rutisson bengt.rutisson at oracle.com
Mon Feb 1 09:50:40 UTC 2016

Hi everyone,

Could I have a couple of reviews for this small change to add a log 
message to print the heap region size?


Currently the heap region size is not explicitly visible in the GC log 
files. Since G1 calculates the region size at startup and then sticks 
with that size, it is enough to log the region size once during 

The new log message looks like this:

[0.013s][info   ][gc,heap] Heap region size: 1M

The test test/gc/logging/TestDeprecatedPrintFlags.java had to be updated 
to handle the padding in the logging of the tags. Before I added this 
message there was logging where the tags looked like this "[gc]", but 
since the new logging appears early in the log file these log message 
now look like "[gc     ]".


More information about the hotspot-gc-dev mailing list