[llvm] r359989 - [SLPVectorizer] Prefer pre-increments. NFCI.
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Sun May 5 10:53:10 PDT 2019
Author: rksimon
Date: Sun May 5 10:53:09 2019
New Revision: 359989
URL: http://llvm.org/viewvc/llvm-project?rev=359989&view=rev
Log:
[SLPVectorizer] Prefer pre-increments. NFCI.
Modified:
llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp
Modified: llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp?rev=359989&r1=359988&r2=359989&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp (original)
+++ llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp Sun May 5 10:53:09 2019
@@ -4350,7 +4350,7 @@ bool BoUpSLP::BlockScheduling::extendSch
<< "\n");
return true;
}
- UpIter++;
+ ++UpIter;
}
if (DownIter != LowerEnd) {
if (&*DownIter == I) {
@@ -4364,7 +4364,7 @@ bool BoUpSLP::BlockScheduling::extendSch
<< "\n");
return true;
}
- DownIter++;
+ ++DownIter;
}
assert((UpIter != UpperEnd || DownIter != LowerEnd) &&
"instruction not found in block");
@@ -6650,7 +6650,7 @@ bool SLPVectorizerPass::vectorizeChainsI
SmallVector<WeakVH, 8> PostProcessInstructions;
SmallDenseSet<Instruction *, 4> KeyNodes;
- for (BasicBlock::iterator it = BB->begin(), e = BB->end(); it != e; it++) {
+ for (BasicBlock::iterator it = BB->begin(), e = BB->end(); it != e; ++it) {
// We may go through BB multiple times so skip the one we have checked.
if (!VisitedInstrs.insert(&*it).second) {
if (it->use_empty() && KeyNodes.count(&*it) > 0 &&
More information about the llvm-commits
mailing list