[PATCH] D149919: [SLP][NFC] Cleanup: Outline the code that vectorizes CmpInsts into a seaparate function.
Alexey Bataev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri May 5 05:41:05 PDT 2023
ABataev added inline comments.
================
Comment at: llvm/include/llvm/Transforms/Vectorize/SLPVectorizer.h:148
+ /// Tries to vectorize \p CmpInts. \Returns true on success.
+ bool vectorizeCmpInsts(const SmallVector<CmpInst *, 4> &CmpInsts,
+ BasicBlock *BB, slpvectorizer::BoUpSLP &R);
----------------
ArrayRef<Value *>
================
Comment at: llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:14417
+ return any_of(V->users(), [V](User *U) {
+ return isa<SelectInst>(U) && cast<SelectInst>(U)->getParent() !=
+ cast<Instruction>(V)->getParent();
----------------
try to replace with dyn_cast
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D149919/new/
https://reviews.llvm.org/D149919
More information about the llvm-commits
mailing list