Skip to content

Commit e288670

Browse files
authored
SLPVectorizer: Use use_empty instead of getNumUses (#136336)
1 parent 430b0c4 commit e288670

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6751,7 +6751,7 @@ BoUpSLP::getReorderingData(const TreeEntry &TE, bool TopToBottom,
67516751
auto PHICompare = [&](unsigned I1, unsigned I2) {
67526752
Value *V1 = TE.Scalars[I1];
67536753
Value *V2 = TE.Scalars[I2];
6754-
if (V1 == V2 || (V1->getNumUses() == 0 && V2->getNumUses() == 0))
6754+
if (V1 == V2 || (V1->use_empty() && V2->use_empty()))
67556755
return false;
67566756
if (isa<PoisonValue>(V1))
67576757
return true;

0 commit comments

Comments
 (0)