RFR (XS): 8021879: G1: G1HeapRegionSize flag value not updated correctly

Jon Masamitsu jon.masamitsu at oracle.com
Tue Jul 30 17:06:01 UTC 2013


Change looks good.

Jon

On 7/30/13 5:11 AM, Bengt Rutisson wrote:
>
> Hi everyone,
>
> Could I have a couple of reviews for this very small change?
>
> http://cr.openjdk.java.net/~brutisso/8021879/webrev.00/
>
> Background:
>
> The G1HeapRegionSize flag is not updated with the actual value of the 
> region size. This makes it impossible to figure out the heap region 
> size using PrintFlagsFinal:
>
> $ java -XX:+UseG1GC -XX:+PrintFlagsFinal -version | grep G1HeapRegionSize
>     uintx G1HeapRegionSize = 0 {product}
>
> Or when setting it to the wrong value (this will actually use a region 
> size of 8m):
>
> $ java -XX:+UseG1GC -XX:G1HeapRegionSize=11m -XX:+PrintFlagsFinal 
> -version | grep G1HeapRegionSize
>     uintx G1HeapRegionSize := 11534336 {product}
>
>
> With the proposed patch I get this output:
>
> $ java -XX:+UseG1GC -XX:+PrintFlagsFinal -version | grep G1HeapRegionSize
>     uintx G1HeapRegionSize                         := 1048576         
> {product}
>
> and:
>
> $ java -XX:+UseG1GC -XX:G1HeapRegionSize=11m -XX:+PrintFlagsFinal 
> -version | grep G1HeapRegionSize
>     uintx G1HeapRegionSize                         := 8388608         
> {product}
>
>
> Here are also some interesting scenarios that are visible with my 
> suggested patch:
>
> $ java -XX:+UseG1GC -Xmx64g  -XX:+PrintFlagsFinal -version | grep 
> G1HeapRegionSize
>     uintx G1HeapRegionSize                         := 1048576         
> {product}
>
> $ java -XX:+UseG1GC -Xms64g -Xmx64g  -XX:+PrintFlagsFinal -version | 
> grep G1HeapRegionSize
>     uintx G1HeapRegionSize                         := 33554432        
> {product}
>
> Thanks,
> Bengt

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


More information about the hotspot-gc-dev mailing list