Skip to content

Commit b149c98

Browse files
committed
[SLP][REVEC] Make vectorizeOperand support vector instructions.
1 parent 6f9d0b8 commit b149c98

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12212,7 +12212,8 @@ Value *BoUpSLP::vectorizeOperand(TreeEntry *E, unsigned NodeIdx,
1221212212
return ShuffleBuilder.finalize(std::nullopt);
1221312213
};
1221412214
Value *V = vectorizeTree(VE, PostponedPHIs);
12215-
if (VF != cast<FixedVectorType>(V->getType())->getNumElements()) {
12215+
if (VF * getNumElements(VL[0]->getType()) !=
12216+
cast<FixedVectorType>(V->getType())->getNumElements()) {
1221612217
if (!VE->ReuseShuffleIndices.empty()) {
1221712218
// Reshuffle to get only unique values.
1221812219
// If some of the scalars are duplicated in the vectorization

0 commit comments

Comments
 (0)