RFR: 8313372: [JVMCI] Export vmIntrinsics::is_intrinsic_available results to JVMCI compilers. [v4]

Vladimir Kozlov kvn at openjdk.org
Thu Aug 10 17:05:58 UTC 2023


On Thu, 10 Aug 2023 16:55:24 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:

>> src/hotspot/cpu/x86/vm_version_x86.hpp line 689:
>> 
>>> 687:   static bool supports_avxonly()      { return ((supports_avx2() || supports_avx()) && !supports_evex()); }
>>> 688:   static bool supports_sha()          { return (_features & CPU_SHA) != 0; }
>>> 689:   static bool supports_fma()          { return (_features & CPU_FMA) != 0 && supports_avx(); }
>> 
>> https://github.com/openjdk/jdk/blob/53ca75b18ea419d469758475fac8352bf915b484/src/hotspot/cpu/x86/vm_version_x86.cpp#L1154-L1158
>> implies fma intrinsic can be used without AVX
>
> https://bugs.openjdk.org/browse/JDK-8181616  added support_avx() check because new Fma vectorization needs AVX: https://cr.openjdk.org/~vdeshpande/8181616/webrev.01/
> Then we hit bug https://bugs.openjdk.org/browse/JDK-8182114 and bandaid it by restoring UseSSE check.
> That change came before 8296168 which switch off UseAVX if UseSSE < 4:
> https://github.com/openjdk/jdk/blob/master/src/hotspot/cpu/x86/vm_version_x86.cpp#L908
> 
> This FMA check happens after UseSSE and UseAVX are set. I suggest to remove UseSSE check here instead and keep support_avx().

Saying that. You may remove support_avx() here but you need to add it to assembler vector instructions which have only support_fma() check now.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/15133#discussion_r1290430146


More information about the graal-dev mailing list