Request for review 7122219: Passed StringTableSize value not verified

harold seigel harold.seigel at oracle.com
Fri Nov 9 11:11:56 PST 2012


Please review the following change to fix bug 7122219.

Summary:  This change prevents the SIGFPE and SIGSEGV problems that can 
occur when using this option. It checks that the specified value is >= 
the current default (1009) and <= the maximum requestable heap size, and 
issues an error if it is not.

This webrev also deletes an unused create_table() method and adds a 
check for integer rollover to method os::malloc().

With this change, if users request an invalid value, they will get an 
error message like this:

    % $JAVA_HOME/bin/java -XX:StringTableSize=1g -cp .. <java-main-class>
    StringTable size of 1073741824 is invalid; must be between 1009 and
    536870911
    Error: Could not create the Java Virtual Machine.
    Error: A fatal exception has occurred. Program will exit.

Open webrev at http://cr.openjdk.java.net/~hseigel/bug_7122219
<http://cr.openjdk.java.net/%7Ehseigel/bug_7122219>
Bug link at http://bugs.sun.com/view_bug.do?bug_id=7122219

The changes were tested with JCK, JPRT, JTREG, and UTE tests, and with 
hand-run tests on 32-bit Linux and 64-bit Windows.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/hotspot-runtime-dev/attachments/20121109/b097c340/attachment.html 


More information about the hotspot-runtime-dev mailing list