> - New AVX2 intrinsics are 1.6x-6.9x faster than Java baseline 
>    - `SignatureBench.MLDSA` is 1.2x-2.2x faster
>    - Note: there is no AVX2-SHA3 intrinsics yet (Being reviewed 
> https://github.com/vpaprotsk/jdk/pull/7)
> - AVX512 intrinsic improvements are 1.24x-1.5x faster then current version 
>   - `SignatureBench.MLDSA` is upto 5% faster, never slower
> 
> Note on intrinsic:
> - The emitted (existing) AVX512 assembler was not "significantly" changed; 
> mostly more efficient instruction selection and tighter register allocation, 
> which allowed removal of NTT loop and stack spill.
> - Code was refactored to allow reuse of same assembler (as possible) for 
> AVX512 and AVX2
> 
> Tests and benchmarks:
> - Added a fuzz test to ensure Java and intrinsic produces exactly same result
> - Added benchmark to measure the performance of intrinsic itself
> 
> make test TEST="test/jdk/sun/security/provider/acvp/Launcher.java 
> test/jdk/sun/security/provider/acvp/ML_DSA_Intrinsic_Test.java"
> make test TEST="test/jdk/sun/security/provider/acvp/Launcher.java 
> test/jdk/sun/security/provider/acvp/ML_DSA_Intrinsic_Test.java" 
> JTREG="JAVA_OPTIONS=-XX:UseAVX=2"
> make test 
> TEST="micro:org.openjdk.bench.javax.crypto.full.SignatureBench.MLDSA" 
> MICRO="JAVA_OPTIONS=-XX:+UnlockDiagnosticVMOptions 
> -XX:+UseDilithiumIntrinsics;FORK=1"
> make test 
> TEST="micro:org.openjdk.bench.javax.crypto.full.SignatureBench.MLDSA" 
> MICRO="JAVA_OPTIONS=-XX:+UnlockDiagnosticVMOptions 
> -XX:-UseDilithiumIntrinsics;FORK=1"

Volodymyr Paprotski has updated the pull request with a new target base due to 
a merge or a rebase. The incremental webrev excludes the unrelated changes 
brought in by the merge/rebase. The pull request contains eight additional 
commits since the last revision:

 - Merge remote-tracking branch 'origin/master' into avx2-ntt
 - next set of comments
 - whitespace
 - address first comments
 - Merge remote-tracking branch 'origin/master' into avx2-ntt
 - add copyright, whitespace and test jtreg tags
 - Fixes and comments from Anas
 - AVX2 and AVX512 intrinsics for MLDSA

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/28136/files
  - new: https://git.openjdk.org/jdk/pull/28136/files/b04f4f0d..cefa021a

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=28136&range=03
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=28136&range=02-03

  Stats: 242832 lines in 2033 files changed: 165193 ins; 41903 del; 35736 mod
  Patch: https://git.openjdk.org/jdk/pull/28136.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/28136/head:pull/28136

PR: https://git.openjdk.org/jdk/pull/28136

Reply via email to