JDK-8205633 : TestOptionsWithRanges.java of '-XX:TLABSize=2147483648' fails intermittently
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 11,12
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: x86_64
  • Submitted: 2018-06-25
  • Updated: 2019-03-09
  • Resolved: 2018-08-13
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11.0.3Fixed
Related Reports
Duplicate :  
Relates :  
Description
The following test failed in the jdk/jdk CI:

runtime/CommandLine/OptionsValidation/TestOptionsWithRanges.java

with the following:

test result: Failed. Execution failed: `main' threw exception: java.lang.RuntimeException: 1 tests failed! (Error processing option TLABSize with valid value '-server -XX:+UseConcMarkSweepGC -XX:TLABSize=2147483648'! JVM output reports a fatal error. JVM exited with code 1 [0x1]!) : expected 1 to equal 0

Here's a snippet from the log file:

---------System.err:(34/2593)----------
Java HotSpot(TM) 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
TEST FAILED: Error processing option TLABSize with valid value '-server -XX:+UseConcMarkSweepGC -XX:TLABSize=2147483648'! JVM output reports a fatal error. JVM exited with code 1 [0x1]!
stdout content[Error occurred during initialization of VM
GC triggered before VM initialization completed. Try increasing NewSize, current value 157M.
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x00007fa4ec066071, pid=7986, tid=7989
#
# JRE version:  (11.0) (fastdebug build )
# Java VM: Java HotSpot(TM) 64-Bit Server VM (fastdebug 11-internal+0-jdk11-jdk.932, mixed mode, tiered, compressed oops, concurrent mark sweep gc, linux-amd64)
# Problematic frame:
# C  [libjimage.so+0x5071]]
stderr content[Java HotSpot(TM) 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
]

java.lang.RuntimeException: 1 tests failed! (Error processing option TLABSize with valid value '-server -XX:+UseConcMarkSweepGC -XX:TLABSize=2147483648'! JVM output reports a fatal error. JVM exited with code 1 [0x1]!)
: expected 1 to equal 0
	at jdk.test.lib.Asserts.fail(Asserts.java:594)
	at jdk.test.lib.Asserts.assertEquals(Asserts.java:205)
	at jdk.test.lib.Asserts.assertEQ(Asserts.java:178)
	at TestOptionsWithRanges.main(TestOptionsWithRanges.java:138)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:115)
	at java.base/java.lang.Thread.run(Thread.java:834)

JavaTest Message: Test threw exception: java.lang.RuntimeException: 1 tests failed! (Error processing option TLABSize with valid value '-server -XX:+UseConcMarkSweepGC -XX:TLABSize=2147483648'! JVM output reports a fatal error. JVM exited with code 1 [0x1]!)
: expected 1 to equal 0
JavaTest Message: shutting down test

STATUS:Failed.`main' threw exception: java.lang.RuntimeException: 1 tests failed! (Error processing option TLABSize with valid value '-server -XX:+UseConcMarkSweepGC -XX:TLABSize=2147483648'! JVM output reports a fatal error. JVM exited with code 1 [0x1]!) : expected 1 to equal 0
Comments
approved subject to codereview
07-11-2018

Fix request This fix imporves the test performance nicely. No dangers as it is a pure test fix. Unfortunately it does not apply cleanly, there is a minor difference in the patch context: http://mail.openjdk.java.net/pipermail/jdk-updates-dev/2018-November/000282.html
06-11-2018

I find it strange that this can be intermittent. Makes me wonder what concurrent initialization we are doing that can sometimes trigger premature GC and sometimes not. We must be treading very close to the line with these extreme flag values.
26-06-2018