[PATCH] D144770: [SLP] Outline GEP chain cost modeling into new TTI interface - NFCI.
Alexey Bataev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Mar 8 08:10:27 PST 2023
ABataev added inline comments.
================
Comment at: llvm/include/llvm/Analysis/TargetTransformInfoImpl.h:1032-1033
+ find_if(Ptrs, [](const Value *V) { return isa<GetElementPtrInst>(V); });
+ if (It == Ptrs.end())
+ return TTI::TCC_Free;
+ assert(all_of(Ptrs,
----------------
Can it happen at all?
================
Comment at: llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:7201
+ if (PtrsRetainedInVecCode.size() == Ptrs.size())
+ VecCost = ScalarCost;
+ else
----------------
Better just return here with diff 0.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D144770/new/
https://reviews.llvm.org/D144770
More information about the llvm-commits
mailing list