RFR: 8308339: AArch64: Remove extra `UseSVE` Predicate in ad file
Fei Gao
fgao at openjdk.org
Wed May 24 02:23:00 UTC 2023
If a match rule belongs to one of the following situations, we can remove extra `UseSVE` Predicate:
1. If any src operand type is `pReg`, which is SVE specific, we can remove `Predicate(UseSVE > 0)`. But if only dst operand type is `pReg`, we can't remove `Predicate(UseSVE > 0)`, since the DFA of matcher selects by src operands and instruction cost, not involving dst operand.
2. If matcher can use src operand type, i.e., `pReg` or `vReg`, to distinguish sve from neon, we can remove
`Predicate(UseSVE == 0)` for rules on neon.
3. When the condition in `Predicate()` is false on current platform, it's definitely impossible to generate the corresponding node pattern from C2. Then we can remove `Predicate()`, like removing `predicate(UseSVE > 0)` for all `PopulateIndex` rules.
After the patch, the code size of libjvm.so decreased from 25.42M to 25.39M, by 25.3K.
Testing:
No new failures found on tier 1 - 3.
No significant performance regression compared with master.
-------------
Commit messages:
- 8308339: AArch64: Remove extra `UseSVE` Predicate in ad file
Changes: https://git.openjdk.org/jdk/pull/14112/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=14112&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8308339
Stats: 302 lines in 2 files changed: 0 ins; 202 del; 100 mod
Patch: https://git.openjdk.org/jdk/pull/14112.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/14112/head:pull/14112
PR: https://git.openjdk.org/jdk/pull/14112
More information about the hotspot-compiler-dev
mailing list