RFR(XXS): 8188109 JVM should print a warning message that -Xshare:on may cause VM to abort start-up

Ioi Lam ioi.lam at oracle.com
Thu May 31 05:33:04 UTC 2018

There is already a flag: -XX:+RequireSharedSpaces, which is turned on 
when you specify -Xshare:on.

I think a better way to make things safer, and still allows a way to 
revert to the old behavior, is to:

[1] make -Xshare:on the same as -Xshare:auto

[2] make RequireSharedSpaces a diagnostic flag as Thomas suggested, so 
people can really shoot themselves in the foot if they want to, but at 
least they know they are doing that.


- Ioi

On 5/30/18 10:20 PM, Thomas Stüfe wrote:
> <snip>
>> Maybe we need -Xshare:on_and_I_really_mean_it ;-)
>> Cheers,
>> David
> How about -Xshare:on, -Xshare:off and an additional diagnostic flag,
> -XX:+ExitOnCDSFail. Gives you the same width of options but since
> diagnostic flags have to be explicitly enabled should make most people
> aware of the problem.
> ..Thomas

More information about the hotspot-runtime-dev mailing list