[9] RFR(XS): 8059596: VM startup fails with 'Invalid code heap sizes' if -XX:ReservedCodeCacheSize is set

Vladimir Ivanov vladimir.x.ivanov at oracle.com
Thu Oct 2 10:49:50 UTC 2014


The fix looks ok.

FTR I find the whole logic in Arguments::set_tiered_flags very fragile.
Considering all the complications we discussed privately, 
CodeCache::initialize_heaps() is a much better place to preserve the 
problematic code cache invariant [1]. But I'm fine with fixing that 
separately.

Best regards,
Vladimir Ivanov

[1] NonMethodCodeHeapSize + NonProfiledCodeHeapSize + 
ProfiledCodeHeapSize) != ReservedCodeCacheSize

On 10/2/14, 1:17 PM, Tobias Hartmann wrote:
> Hi,
>
> please review this small patch.
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-8059596
> Webrev: http://cr.openjdk.java.net/~thartmann/8059596/webrev.00/
>
> Problem:
> The VM startup fails with 'Invalid code heap sizes' if
> -XX:ReservedCodeCacheSize >= 240M is specified. The problem is that in
> Arguments::set_tiered_flags() the code cache size is increased by 5 if
> TieredCompilation is enabled. This should only be done for default values.
>
> Solution:
> Add missing FLAG_IS_DEFAULT(ReservedCodeCacheSize) check.
>
> Thanks,
> Tobias


More information about the hotspot-dev mailing list