[llvm] [VPlan] Remove VPWidenRecipe constructor with no underlying instruction. NFCI (PR #166521)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 3 23:05:54 PST 2025


================
@@ -1447,22 +1447,15 @@ class LLVM_ABI_FOR_TEST VPWidenRecipe : public VPRecipeWithIRFlags,
   unsigned Opcode;
 
 public:
-  VPWidenRecipe(unsigned Opcode, ArrayRef<VPValue *> Operands,
-                const VPIRFlags &Flags, const VPIRMetadata &Metadata,
-                DebugLoc DL)
-      : VPRecipeWithIRFlags(VPDef::VPWidenSC, Operands, Flags, DL),
-        VPIRMetadata(Metadata), Opcode(Opcode) {}
-
   VPWidenRecipe(Instruction &I, ArrayRef<VPValue *> Operands)
       : VPRecipeWithIRFlags(VPDef::VPWidenSC, Operands, I), VPIRMetadata(I),
         Opcode(I.getOpcode()) {}
 
   ~VPWidenRecipe() override = default;
 
   VPWidenRecipe *clone() override {
-    auto *R =
-        new VPWidenRecipe(getOpcode(), operands(), *this, *this, getDebugLoc());
-    R->setUnderlyingValue(getUnderlyingValue());
+    auto *R = new VPWidenRecipe(*getUnderlyingInstr(), operands());
----------------
lukel97 wrote:

Rebased and now explicit in 7976cd3a757cfc6824f16b3d2bef67e265e63bb1

https://github.com/llvm/llvm-project/pull/166521


More information about the llvm-commits mailing list