mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-21 08:17:40 +00:00
SLP Vectorizer: Disable the vectorization of non power of two chains, such as <3 x float>, because we dont have a good cost model for these types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187265 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -1664,23 +1664,7 @@ bool SLPVectorizer::vectorizeStoreChain(ArrayRef<Value *> Chain,
|
||||
}
|
||||
}
|
||||
|
||||
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.
|
||||
R.buildTree(Chain);
|
||||
|
||||
int Cost = R.getTreeCost();
|
||||
|
||||
if (Cost < CostThreshold) {
|
||||
DEBUG(dbgs() << "SLP: Found store chain cost = " << Cost
|
||||
<< " for size = " << ChainLen << "\n");
|
||||
R.vectorizeTree();
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
bool SLPVectorizer::vectorizeStores(ArrayRef<StoreInst *> Stores,
|
||||
|
||||
Reference in New Issue
Block a user