[PATCH] D23473: [LSV] Use a set rather than an ArraySlice at the end of getVectorizablePrefix. NFC
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 12 16:51:21 PDT 2016
arsenm accepted this revision.
arsenm added a reviewer: arsenm.
arsenm added a comment.
This revision is now accepted and ready to land.
LGTM
================
Comment at: llvm/lib/Transforms/Vectorize/LoadStoreVectorizer.cpp:520
@@ -519,7 +519,3 @@
// order.)
- auto VectorizableChainInstrs =
- makeArrayRef(ChainInstrs.data(), ChainInstrIdx);
- unsigned ChainIdx, ChainLen;
- for (ChainIdx = 0, ChainLen = Chain.size(); ChainIdx < ChainLen; ++ChainIdx) {
- Instruction *I = Chain[ChainIdx];
- if (!is_contained(VectorizableChainInstrs, I))
+ SmallPtrSet<Instruction *, 16> VectorizableChainInstrs(
+ ChainInstrs.begin(), ChainInstrs.begin() + ChainInstrIdx);
----------------
16 seems high. 8?
https://reviews.llvm.org/D23473
More information about the llvm-commits
mailing list