[PATCH] D127727: [RISCV] Turn on SeparateConstOffsetFromGEPPass for RISC-V target and added optional modification strategy in it
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 14 08:48:48 PDT 2022
craig.topper added a comment.
This should be two patches, one changing the pass and one enabling for RISC-V.
================
Comment at: llvm/lib/Target/RISCV/RISCVTargetMachine.cpp:171
addPass(createRISCVGatherScatterLoweringPass());
-
+ if (TM->getOptLevel() == CodeGenOpt::Aggressive) {
+ addPass(createSeparateConstOffsetFromGEPPass(false, true));
----------------
Can we add a command line option to control this like AArch64 and PowerPC have?
================
Comment at: llvm/test/Transforms/SeparateConstOffsetFromGEP/RISCV/split-gep.ll:1
-; RUN: opt < %s -mtriple=riscv64-unknown-elf -passes='separate-const-offset-from-gep,early-cse' \
-; RUN: opt < %s -mtriple=riscv64-unknown-elf -passes='separate-const-offset-from-gep,early-cse' \
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
+; RUN: opt < %s -mtriple=riscv64-unknown-elf -passes='separate-const-offset-from-gep<check-profit>,early-cse' \
----------------
This test doesn't exist in the repo. Where is the patch that adds it?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D127727/new/
https://reviews.llvm.org/D127727
More information about the llvm-commits
mailing list