RFR: 8318509: x86 count_positives intrinsic broken for -XX:AVX3Threshold=0
Claes Redestad
redestad at openjdk.org
Thu Oct 19 13:00:47 UTC 2023
The AVX-512 implementation of count_positives is broken when there are negative values in the tail block, since the len register is repurposed to then re-read as-if it still contained the original value.
Proposed fix is to restore len from the value in tmp1, which at this point holds the count of bytes in the tail.
Existing TestCountPositives test is pretty exhaustive and just needs to be run explicitly with AVX3Threshold=0 enabled.
-------------
Commit messages:
- Add test run with AVX3Threshold=0 to TestCountPositives test
- Merge branch 'master' into avx3_countPositives
- Fix AVX3 implementation of countPositives stub
Changes: https://git.openjdk.org/jdk/pull/16267/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=16267&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8318509
Stats: 32 lines in 2 files changed: 22 ins; 2 del; 8 mod
Patch: https://git.openjdk.org/jdk/pull/16267.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/16267/head:pull/16267
PR: https://git.openjdk.org/jdk/pull/16267
More information about the hotspot-compiler-dev
mailing list