RFR: 8328264: AArch64: remove UseNeon condition in CRC32 intrinsic

Hamlin Li mli at openjdk.org
Fri Mar 15 15:45:56 UTC 2024


Hi,
Can you review the simple patch?
Thanks

FYI: Discussed https://github.com/openjdk/jdk/pull/18294#issuecomment-1997727704, this usage of UseNeon flag should be removed, as neon is working by default, and UseNeon could be false, so this means the intrinsic code of Neon can be skipped unexpected.

## Performance
Tested jmh `TestCRC32` with "-XX:-UseCRC32 -XX:-UseCryptoPmullForCRC32" 
Before

Benchmark                    (count)  Mode  Cnt      Score   Error  Units
TestCRC32.testCRC32Update         64  avgt    2     53.696          ns/op
TestCRC32.testCRC32Update        128  avgt    2    104.942          ns/op
TestCRC32.testCRC32Update        256  avgt    2    207.147          ns/op
TestCRC32.testCRC32Update        512  avgt    2    411.179          ns/op
TestCRC32.testCRC32Update       2048  avgt    2   1608.388          ns/op
TestCRC32.testCRC32Update      16384  avgt    2  12763.513          ns/op
TestCRC32.testCRC32Update      65536  avgt    2  51024.246          ns/op


After

Benchmark                    (count)  Mode  Cnt      Score   Error  Units
TestCRC32.testCRC32Update         64  avgt    2     40.172          ns/op
TestCRC32.testCRC32Update        128  avgt    2     56.754          ns/op
TestCRC32.testCRC32Update        256  avgt    2     89.743          ns/op
TestCRC32.testCRC32Update        512  avgt    2    156.726          ns/op
TestCRC32.testCRC32Update       2048  avgt    2    579.776          ns/op
TestCRC32.testCRC32Update      16384  avgt    2   4624.023          ns/op
TestCRC32.testCRC32Update      65536  avgt    2  18505.180          ns/op

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

Commit messages:
 - Initial commit

Changes: https://git.openjdk.org/jdk/pull/18328/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=18328&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8328264
  Stats: 126 lines in 1 file changed: 24 ins; 24 del; 78 mod
  Patch: https://git.openjdk.org/jdk/pull/18328.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/18328/head:pull/18328

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


More information about the hotspot-dev mailing list