[llvm] r184527 - SLP Vectorizer: do not search for store-chains that are wider than the vector-register size.
Nadav Rotem
nrotem at apple.com
Thu Jun 20 21:18:13 PDT 2013
Author: nadav
Date: Thu Jun 20 23:18:13 2013
New Revision: 184527
URL: http://llvm.org/viewvc/llvm-project?rev=184527&view=rev
Log:
SLP Vectorizer: do not search for store-chains that are wider than the vector-register size.
Modified:
llvm/trunk/lib/Transforms/Vectorize/VecUtils.cpp
Modified: llvm/trunk/lib/Transforms/Vectorize/VecUtils.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Vectorize/VecUtils.cpp?rev=184527&r1=184526&r2=184527&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Vectorize/VecUtils.cpp (original)
+++ llvm/trunk/lib/Transforms/Vectorize/VecUtils.cpp Thu Jun 20 23:18:13 2013
@@ -141,9 +141,11 @@ bool BoUpSLP::vectorizeStoreChain(ArrayR
}
}
- if (Changed)
- return true;
+ if (Changed || ChainLen > VF)
+ return Changed;
+ // Handle short chains. This helps us catch types such as <3 x float> that
+ // are smaller than vector size.
int Cost = getTreeCost(Chain);
if (Cost < CostThreshold) {
DEBUG(dbgs() << "SLP: Found store chain cost = " << Cost
More information about the llvm-commits
mailing list