RFR: 8344118: C2 SuperWord: add VectorThroughputForIterationCount benchmark [v2]

Emanuel Peter epeter at openjdk.org
Wed Nov 20 14:35:36 UTC 2024


> Took idea of benchmark from here https://github.com/openjdk/jdk/pull/14581
> 
> It will be important for the efforts in:
> [JDK-8344085](https://bugs.openjdk.org/browse/JDK-8344085): C2 SuperWord: improve vectorization for small loop iteration count
> 
> I ran the plots for `byte, int, long`.
> We have aligned/unaligned scenarios, and compute-bound vs memory-bound scenarios.
> 
> We can very clearly see the effect of vectorization, and that with increasing `size`, we get increasingly better performance. But we can also see the effect of pre/post loops: this creates the saw-tooth curve.
> 
> ---------------------------------------------------
> **Results**
> 
> red: normal -> saw-tooth
> green: randomized offsets -> more "smooth"
> 
> linux_x64
> ![linux_x64](https://github.com/user-attachments/assets/1e63b47f-16a6-4766-985d-9da4cad25505)
> 
> linux_aarch64
> ![linux_aarch64](https://github.com/user-attachments/assets/77e9a880-32eb-43f8-a84b-16f39c1c2a62)
> 
> macosx_x64
> ![macosx_x64](https://github.com/user-attachments/assets/ab730367-d684-475c-b96d-e1093f56e776)
> 
> macosx_aarch64
> ![macosx_aarch64](https://github.com/user-attachments/assets/551484f5-79c7-41ea-b54d-e038d8c7b048)
> 
> windows_x64
> ![windows_x64](https://github.com/user-attachments/assets/3801577f-ac53-48ce-9b46-a2c9f0a2ddfe)

Emanuel Peter 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 seven additional commits since the last revision:

 - Merge branch 'master' into JDK-8344118-VectorThroughputForIterationCount-benchmark
 - whitespace
 - Merge branch 'master' into JDK-8344118-VectorThroughputForIterationCount-benchmark
 - Merge branch 'master' into JDK-8344118-VectorThroughputForIterationCount-benchmark
 - Merge branch 'master' into JDK-8344118-VectorThroughputForIterationCount-benchmark
 - Merge branch 'master' into JDK-8344118-VectorThroughputForIterationCount-benchmark
 - JDK-8344118

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/22070/files
  - new: https://git.openjdk.org/jdk/pull/22070/files/cb9c6fd1..c3930c4d

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=22070&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=22070&range=00-01

  Stats: 9229 lines in 369 files changed: 3856 ins; 3824 del; 1549 mod
  Patch: https://git.openjdk.org/jdk/pull/22070.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/22070/head:pull/22070

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


More information about the hotspot-compiler-dev mailing list