JDK-8209735 : Disable avx512 by default
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 9,10,11
  • Priority: P1
  • Status: Closed
  • Resolution: Fixed
  • CPU: x86
  • Submitted: 2018-08-20
  • Updated: 2018-08-29
  • Resolved: 2018-08-20
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 12
11 b28Fixed 12Fixed
Related Reports
Relates :  
Description
I am working on JDK-8209594 (short branches distance too big when avx512 is used) and I found more issues with it and I need time to find all cases.

Some instructions are totally wrong (copy-paste error) when register >=16 are used:
http://hg.openjdk.java.net/jdk/jdk11/file/f729ca27cf9a/src/hotspot/cpu/x86/macroAssembler_x86.cpp#l4680
http://hg.openjdk.java.net/jdk/jdk11/file/f729ca27cf9a/src/hotspot/cpu/x86/macroAssembler_x86.cpp#l4581

Also some vector predicated in .ad file are wrong for the same issue:
http://hg.openjdk.java.net/jdk/jdk11/file/f729ca27cf9a/src/hotspot/cpu/x86/x86.ad#l5647

I am currently trying to instrument code to emulate situation when only xmm16-31 are used, as we discussed before, to find incorrect cases and I need time for that.

At this later time I want to switch off avx512 in JDK 11.
Comments
Fix request approved.
20-08-2018

Review thread: http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/2018-August/030202.html
20-08-2018

Fix Request. The fix is small and safe. It disables functionality which cause issues like JDK-8207746 and JDK-8209594. This configuration (no avx512 instructions) is tested mostly by our testing (due to small number avx512 machines we have).
20-08-2018

Proposed fix: diff -r 7339b9e38182 src/hotspot/cpu/x86/globals_x86.hpp --- a/src/hotspot/cpu/x86/globals_x86.hpp +++ b/src/hotspot/cpu/x86/globals_x86.hpp @@ -119,7 +119,7 @@ product(bool, UseStoreImmI16, true, \ "Use store immediate 16-bits value instruction on x86") \ \ - product(intx, UseAVX, 3, \ + product(intx, UseAVX, 2, \ "Highest supported AVX instructions set on x86/x64") \ range(0, 99) \
20-08-2018

This code was contributed by Intel in JDK 9 JDK-8140779: http://hg.openjdk.java.net/jdk9/jdk9/hotspot/rev/b57d415bdaa9
20-08-2018