[PATCH] D150665: [RISCV] Handle addimm chains in SelectAddrRegImm
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 17 11:02:25 PDT 2023
craig.topper added a comment.
I feel like this should be handled where the chain was formed or in DAG combine. The whole reason the chain exists is to provide a common base. If the common base isn't right we should fix that.
================
Comment at: llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp:2318
+ if (!(Subtarget->hasStdExtC() || Subtarget->hasStdExtZca() ||
+ Subtarget->hasStdExtZcf() || Subtarget->hasStdExtZcd()))
+ return false;
----------------
Zcf and Zcd imply Zca so I don't think you need to check them. You can also hasStdExtCOrZca.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D150665/new/
https://reviews.llvm.org/D150665
More information about the llvm-commits
mailing list