JDK-8237055 : [TESTBUG] compiler/c2/TestJumpTable.java fails with release VMs
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 14,15
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2020-01-14
  • Updated: 2022-06-27
  • Resolved: 2020-01-14
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 JDK 13 JDK 14 JDK 15
11.0.8-oracleFixed 13.0.4Fixed 14 b32Fixed 15Fixed
Related Reports
Relates :  
Description
## Symptom
```
STDERR:
Error: VM option 'UseSwitchProfiling' is diagnostic and must be enabled via -XX:+UnlockDiagnosticVMOptions.
Error: The unlock option must precede 'UseSwitchProfiling'.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
```

## Fix
```
diff -r db9bdbeaed29 test/hotspot/jtreg/compiler/c2/TestJumpTable.java
--- a/test/hotspot/jtreg/compiler/c2/TestJumpTable.java Mon Jan 13 14:09:30 2020 -0800
+++ b/test/hotspot/jtreg/compiler/c2/TestJumpTable.java Tue Jan 14 09:01:21 2020 +0800
@@ -26,7 +26,7 @@
  * @bug 8229855
  * @summary Test jump table with key value that gets out of bounds after loop unrolling.
  * @run main/othervm -XX:CompileCommand=dontinline,compiler.c2.TestJumpTable::test*
- *                   -Xbatch -XX:-TieredCompilation -XX:-UseSwitchProfiling
+ *                   -Xbatch -XX:+UnlockDiagnosticVMOptions -XX:-TieredCompilation -XX:-UseSwitchProfiling
  *                   compiler.c2.TestJumpTable
  */
```
Comments
Fix request (13u): The original change applies cleanly, passes tier1 and tier2 tests.
03-06-2020

Fix Request (11u) This is a followup for JDK-8229855. Patch applies cleanly to 11u, but requires JDK-8229158 to be applied first to match experimental->diagnostic demotion. After that, the affected test starts to pass.
28-02-2020

URL: https://hg.openjdk.java.net/jdk/jdk14/rev/247b7fe0c11d User: thartmann Date: 2020-01-14 11:17:31 +0000
14-01-2020

ILW = Test fails due to flag not available in product build (regression in JDK 14), single test, no workaround = MMH = P3
14-01-2020

RFR: https://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/2020-January/036738.html
14-01-2020