[llvm] 0979680 - [VPlan] Remove dead member functions (NFC) (#208936)
via llvm-commits
llvm-commits at lists.llvm.org
Sat Jul 11 12:27:40 PDT 2026
Author: Florian Hahn
Date: 2026-07-11T19:27:36Z
New Revision: 09796808802f99c30a23bc0f2cd68243764e84ab
URL: https://github.com/llvm/llvm-project/commit/09796808802f99c30a23bc0f2cd68243764e84ab
DIFF: https://github.com/llvm/llvm-project/commit/09796808802f99c30a23bc0f2cd68243764e84ab.diff
LOG: [VPlan] Remove dead member functions (NFC) (#208936)
Remove member functions with no remaining callers anywhere in the tree:
- VPExpressionRecipe::getOperandOfResultType
- VPBlockBase::getSingleHierarchicalSuccessor
- VPIRFlags::hasNonNegFlag
- VPWidenIntOrFpInductionRecipe::getStartValue, which is an exact
duplicate of the inherited VPWidenInductionRecipe::getStartValue.
Added:
Modified:
llvm/lib/Transforms/Vectorize/VPlan.h
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/Vectorize/VPlan.h b/llvm/lib/Transforms/Vectorize/VPlan.h
index 1ce5786793c49..46e2ad4716323 100644
--- a/llvm/lib/Transforms/Vectorize/VPlan.h
+++ b/llvm/lib/Transforms/Vectorize/VPlan.h
@@ -258,12 +258,6 @@ class LLVM_ABI_FOR_TEST VPBlockBase {
return getEnclosingBlockWithSuccessors()->getSuccessors();
}
- /// \return the hierarchical successor of this VPBlockBase if it has a single
- /// hierarchical successor. Otherwise return a null pointer.
- VPBlockBase *getSingleHierarchicalSuccessor() {
- return getEnclosingBlockWithSuccessors()->getSingleSuccessor();
- }
-
/// \return the predecessors either attached directly to this VPBlockBase or,
/// if this VPBlockBase is the entry block of a VPRegionBlock and has no
/// predecessors of its own, search recursively for the first enclosing
@@ -1004,9 +998,6 @@ class VPIRFlags {
LLVM_ABI_FOR_TEST FastMathFlags getFastMathFlagsOrNone() const;
- /// Returns true if the recipe has non-negative flag.
- bool hasNonNegFlag() const { return OpType == OperationType::NonNegOp; }
-
bool isNonNeg() const {
assert(OpType == OperationType::NonNegOp &&
"recipe doesn't have a NNEG flag");
@@ -2653,9 +2644,6 @@ class VPWidenIntOrFpInductionRecipe : public VPWidenInductionRecipe,
"expandVPWidenIntOrFpInductionRecipe");
}
- /// Returns the start value of the induction.
- VPIRValue *getStartValue() const { return cast<VPIRValue>(getOperand(0)); }
-
/// If the recipe has been unrolled, return the VPValue for the induction
/// increment, otherwise return null.
VPValue *getSplatVFValue() const {
@@ -3647,14 +3635,6 @@ class VPExpressionRecipe : public VPSingleDefRecipe {
return new VPExpressionRecipe(ExpressionType, NewExpressiondRecipes);
}
- /// Return the VPValue to use to infer the result type of the recipe.
- VPValue *getOperandOfResultType() const {
- unsigned OpIdx =
- cast<VPReductionRecipe>(ExpressionRecipes.back())->isConditional() ? 2
- : 1;
- return getOperand(getNumOperands() - OpIdx);
- }
-
/// Insert the recipes of the expression back into the VPlan, directly before
/// the current recipe. Leaves the expression recipe empty, which must be
/// removed before codegen.
More information about the llvm-commits
mailing list