-
Bug
-
Resolution: Fixed
-
P5
-
9
-
b64
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8082611 | emb-9 | Dmitry Dmitriev | P5 | Resolved | Fixed | team |
Fix for JDK-6521376 add explicit processing of MaxTenuringThreshold XX option. When bad value for MaxTenuringThreshold is passed(e.g. negative value for unsigned option "-XX:MaxTenuringThreshold=-1"), then function print warning and continue execution with default value(0).
This behavior differs from Java 8. Java 8 process this situation in common way for unsigned options, i.e. print waring and reports a error.
Example:
1) Java 8u40
java -XX:MaxTenuringThreshold=-1 -version
Improperly specified VM option 'MaxTenuringThreshold=-1'
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
2) Java 9 b55
java -XX:MaxTenuringThreshold=-1 -version
Invalid MaxTenuringThreshold: -XX:MaxTenuringThreshold=-1
java version "1.9.0-ea"
Java(TM) SE Runtime Environment (build 1.9.0-ea-b55)
Java HotSpot(TM) 64-Bit Server VM (build 1.9.0-ea-b55, mixed mode)
As we see, Java 8u40 and Java 9 b55 reports about wrong option value, but Java 8u40 exit with error and Java 9 b55 successfully exit.
So, Java 9 behavior must be corrected to match the common behavior(exit JVM and print common error message)
This behavior differs from Java 8. Java 8 process this situation in common way for unsigned options, i.e. print waring and reports a error.
Example:
1) Java 8u40
java -XX:MaxTenuringThreshold=-1 -version
Improperly specified VM option 'MaxTenuringThreshold=-1'
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
2) Java 9 b55
java -XX:MaxTenuringThreshold=-1 -version
Invalid MaxTenuringThreshold: -XX:MaxTenuringThreshold=-1
java version "1.9.0-ea"
Java(TM) SE Runtime Environment (build 1.9.0-ea-b55)
Java HotSpot(TM) 64-Bit Server VM (build 1.9.0-ea-b55, mixed mode)
As we see, Java 8u40 and Java 9 b55 reports about wrong option value, but Java 8u40 exit with error and Java 9 b55 successfully exit.
So, Java 9 behavior must be corrected to match the common behavior(exit JVM and print common error message)
- backported by
-
JDK-8082611 Java 9 process negative MaxTenuringThreshold in different way than Java 8
-
- Resolved
-