[PATCH] D116307: [RISCV] Teach VSETVLInsert to eliminate redundant vsetvli for vmv.s.x and vfmv.s.f.
Craig Topper via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 28 20:59:37 PST 2021
craig.topper added inline comments.
================
Comment at: llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp:68
: AVLImm(0), TailAgnostic(false), MaskAgnostic(false), MaskRegOp(false),
StoreOp(false), SEWLMULRatioOnly(false) {}
----------------
Do we need to init ScalarMovOp here?
================
Comment at: llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp:101
+ bool hasZeroAVL() const {
+ if (hasAVLImm()) {
+ return getAVLImm() == 0;
----------------
Drop curly braces around single line if bodies
================
Comment at: llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp:106
+ }
+ bool hasPositiveAVL() const {
+ if (hasAVLImm()) {
----------------
This is really `hasNonZeroAVL` rather than positive right?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D116307/new/
https://reviews.llvm.org/D116307
More information about the llvm-commits
mailing list