[PATCH] D93476: [LV][ARM] Inloop reduction cost modelling
Sjoerd Meijer via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 21 05:24:20 PST 2021
SjoerdMeijer added inline comments.
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:6839
+ RetI->getOpcode() == Instruction::ZExt) &&
+ RetI->hasOneUser())
+ RetI = RetI->user_back();
----------------
Nit: both cases check for hasOneUser. Can we return early if doesn't have one user?
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:6887
+ Instruction *Op1 = dyn_cast<Instruction>(Mul->getOperand(1));
+ if (Op0 && Op1 && (isa<SExtInst>(Op0) || isa<ZExtInst>(Op0)) &&
+ Op0->getOpcode() == Op1->getOpcode() &&
----------------
Do we also need to check Op1 for ZExt or SExt?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D93476/new/
https://reviews.llvm.org/D93476
More information about the llvm-commits
mailing list