Skip to content

Commit 1a34007

Browse files
authored
[VPlan] Inline WidenSelect::isInvariantCond (NFC) (llvm#166742)
VPWidenSelectRecipe::isInvariantCond has a sole use: inline it in the use-site, as it is not meant to be used standalone.
1 parent 54c9ddd commit 1a34007

File tree

1 file changed

+1
-5
lines changed
  • llvm/lib/Transforms/Vectorize

1 file changed

+1
-5
lines changed

llvm/lib/Transforms/Vectorize/VPlan.h

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1762,15 +1762,11 @@ struct LLVM_ABI_FOR_TEST VPWidenSelectRecipe : public VPRecipeWithIRFlags,
17621762
return getOperand(0);
17631763
}
17641764

1765-
bool isInvariantCond() const {
1766-
return getCond()->isDefinedOutsideLoopRegions();
1767-
}
1768-
17691765
/// Returns true if the recipe only uses the first lane of operand \p Op.
17701766
bool usesFirstLaneOnly(const VPValue *Op) const override {
17711767
assert(is_contained(operands(), Op) &&
17721768
"Op must be an operand of the recipe");
1773-
return Op == getCond() && isInvariantCond();
1769+
return Op == getCond() && Op->isDefinedOutsideLoopRegions();
17741770
}
17751771
};
17761772

0 commit comments

Comments
 (0)