JDK-8177918 : Test compiler/codecache/CheckReservedInitialCodeCacheSizeArgOrder.java fails
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 9
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2017-03-31
  • Updated: 2017-04-03
  • Resolved: 2017-04-03
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 9
9Resolved
Related Reports
Duplicate :  
Description
The test which checks that the order in which ReversedCodeCacheSize and InitialCodeCacheSize are passed to the VM is irrelevant (compiler/codecache/CheckReservedInitialCodeCacheSizeArgOrder.java) fails:

----------System.out:(2/1144)----------
Command line: [/export/home/aginfra/CommonData/TEST_JAVA_HOME/bin/java -d64 -cp /scratch/export/home/aginfra/sandbox/results/workDir/classes/1/compiler/codecache:/scratch/export/home/aginfra/CommonData/j2se_jdk/hotspot/test/compiler/codecache:/scratch/export/home/aginfra/sandbox/results/workDir/classes/1/test/lib:/scratch/export/home/aginfra/CommonData/j2se_jdk/test/lib:/scratch/export/home/aginfra/CommonData/jtreg_dir/lib/javatest.jar:/scratch/export/home/aginfra/CommonData/jtreg_dir/lib/jtreg.jar -XX:InitialCodeCacheSize=4m -XX:ReservedCodeCacheSize=8m -version ]
Command line: [/export/home/aginfra/CommonData/TEST_JAVA_HOME/bin/java -d64 -cp /scratch/export/home/aginfra/sandbox/results/workDir/classes/1/compiler/codecache:/scratch/export/home/aginfra/CommonData/j2se_jdk/hotspot/test/compiler/codecache:/scratch/export/home/aginfra/sandbox/results/workDir/classes/1/test/lib:/scratch/export/home/aginfra/CommonData/j2se_jdk/test/lib:/scratch/export/home/aginfra/CommonData/jtreg_dir/lib/javatest.jar:/scratch/export/home/aginfra/CommonData/jtreg_dir/lib/jtreg.jar -XX:ReservedCodeCacheSize=8m -XX:InitialCodeCacheSize=4m -version ]
----------System.err:(13/850)----------
java.lang.RuntimeException: Test failed
	at compiler.codecache.CheckReservedInitialCodeCacheSizeArgOrder.main(CheckReservedInitialCodeCacheSizeArgOrder.java:54)
	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:547)
	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:110)
	at java.base/java.lang.Thread.run(Thread.java:844)

JavaTest Message: Test threw exception: java.lang.RuntimeException: Test failed
JavaTest Message: shutting down test

STATUS:Failed.`main' threw exception: java.lang.RuntimeException: Test failed
Comments
The test sets -XX:ReservedCodeCacheSize=8m which is not enough for VM startup on machines with many cores and with a debug build. The machine has 256 cores and the VM therefore creates 36 compiler threads. Each compiler thread requires extra space in the code cache for temporary buffers: java -XX:ReservedCodeCacheSize=10M -XX:+PrintCodeCache -version CodeCache: size=10240Kb used=8875Kb max_used=8881Kb free=1364Kb bounds [0x00007efd50a93000, 0x00007efd51343000, 0x00007efd51493000] total_blobs=915 nmethods=36 adapters=724 The test fails because the output varies according to where we fail during startup. For example, "Java HotSpot(TM) 64-Bit Server VM warning: Initialization of C1 CompilerThread34 thread failed (no space to run compilers)" vs. "Java HotSpot(TM) 64-Bit Server VM warning: Initialization of C1 CompilerThread33 thread failed (no space to run compilers)" This is a duplicate of JDK-8177899.
03-04-2017