RFR (XS): 8021879: G1: G1HeapRegionSize flag value not updated correctly
Bengt Rutisson
bengt.rutisson at oracle.com
Wed Jul 31 08:12:04 UTC 2013
On 7/30/13 7:06 PM, Jon Masamitsu wrote:
> Change looks good.
Thanks for the review Jon!
I added a regression test and provided a new webrev. The code change is
still the same. Let me know if you have any issues with the test
otherwise I'll push if Thomas is happy with the test.
http://cr.openjdk.java.net/~brutisso/8021879/webrev.01/
Thanks,
Bengt
>
> 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
>
>
More information about the hotspot-gc-dev
mailing list