RFR: 8341527: AVX-512 intrinsic for SHA3 [v4]

Volodymyr Paprotski duke at openjdk.org
Wed Oct 16 17:05:15 UTC 2024


On Tue, 15 Oct 2024 15:51:34 GMT, Ferenc Rakoczi <duke at openjdk.org> wrote:

>> src/hotspot/cpu/x86/vm_version_x86.cpp line 1316:
>> 
>>> 1314:   }
>>> 1315: 
>>> 1316:   if (UseAVX > 2) {
>> 
>> Should be `#ifdef _LP64`. (Similar format from above). Need to look up the cpu features required for the instructions in the intrinsic..
>
> Added the #ifdef.

The 'rest' of the comment I owed you.. need `AVX512F`, `AVX512DQ`, `AVX512BW`.
So you will need `supports_avx512bwdq()` here

"Showing my (math) work.."

grep '__ ' src/hotspot/cpu/x86/stubGenerator_x86_64_sha3.cpp | sed -e 's| *__ *||' -e 's|(.*||' | sort -u
(only using the full 512 versions, no need for VL)
evmovdquq  AVX512F
evmovdquw  AVX512BW
evpermt2q  AVX512F
evprolq    AVX512F
evprolvq   AVX512F
evpxorq    AVX512F
vpternlogq AVX512F
kmovbl     AVX512DQ
...

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21352#discussion_r1803495632


More information about the hotspot-dev mailing list