JDK-8273806 : compiler/cpuflags/TestSSE4Disabled.java should test for CPU feature explicitly
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 11,17,18
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2021-09-15
  • Updated: 2022-12-02
  • Resolved: 2021-09-16
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 17 JDK 18
11.0.19-oracleFixed 17.0.2Fixed 18 b16Fixed
Related Reports
Relates :  
Description
JDK-8158214 added a test that verifies that machines with SSE4 support do not crash when lower SSE level is required. But it tests for CPU capabilities weirdly.

This _tangentially_ manifests when running the test with Zero:

```
$ CONF=linux-x86_64-zero-fastdebug make exploded-test TEST=compiler/cpuflags/TestSSE4Disabled.java
...
STDERR:
Unrecognized VM option 'UseSSE=3'
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
```

I think we can test that target CPU supports SSE4, and only run the test then. It would implicitly fix Zero test failure too, as Zero impersonates a "generic" featureless CPU. Plus, it would stop running the -Xcomp test on arches that do not actually need to run this test.
Comments
Fix Request (17u) Fixes the test on Zero. Applies cleanly.
01-10-2021

Changeset: 09ecb119 Author: Aleksey Shipilev <shade@openjdk.org> Date: 2021-09-16 08:23:55 +0000 URL: https://git.openjdk.java.net/jdk/commit/09ecb11927f0042ddc0c5c23d747b275ab70b36b
16-09-2021

ILW = Single test failure on Zero due to badly testing CPU capabilities, only affects Zero?, no workaround = MLH = P4
15-09-2021