[llvm] [RISCV] Add a pass to remove ADDI by reassociating to fold into load/store address. (PR #127151)
Alex Bradbury via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 19 05:49:27 PST 2025
https://github.com/asb approved this pull request.
LGTM. Here are the results I get for dynamic instruction count impact as measured via qemu-user plugin (SPEC 2017, train dataset, -march=rv64gc and no LTO). Matches your comment on the leela_r impact, but there are gains for nab_r and xz_r too:
```
500.perlbench_r 174012006613 173921196845 -0.05%
502.gcc_r 218650852693 218971034713 0.15%
505.mcf_r 131573660594 131203488777 -0.28%
508.namd_r 217509594816 217412978405 -0.04%
510.parest_r 289306119855 289304644615 -0.00%
511.povray_r 31637559090 31636827075 -0.00%
519.lbm_r 95897914890 95897914899 0.00%
520.omnetpp_r 134722898826 134565059708 -0.12%
523.xalancbmk_r 281039434219 281025840539 -0.00%
525.x264_r 380167866567 380055777956 -0.03%
526.blender_r 659969371927 659746540280 -0.03%
531.deepsjeng_r 352331420401 349545945804 -0.79%
538.imagick_r 238558760759 238558763924 0.00%
541.leela_r 421624218698 406574474471 -3.57%
544.nab_r 414398714724 401491106871 -3.11%
557.xz_r 131583790604 130014971282 -1.19%
```
https://github.com/llvm/llvm-project/pull/127151
More information about the llvm-commits
mailing list