Skip to content

Commit 536d78c

Browse files
committed
[VPlan] Remove VPInstruction::setUnderlyingInstr (NFCI).
VPInstruction doesn't rely on the underlying instruction any longer for codegen, remove the unneeded setUnderlyingInstr.
1 parent cc2fe7b commit 536d78c

File tree

2 files changed

+0
-4
lines changed

2 files changed

+0
-4
lines changed

llvm/lib/Transforms/Vectorize/VPlan.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1177,9 +1177,6 @@ class VPInstruction : public VPRecipeWithIRFlags {
11771177
bool isFPMathOp() const;
11781178
#endif
11791179

1180-
protected:
1181-
void setUnderlyingInstr(Instruction *I) { setUnderlyingValue(I); }
1182-
11831180
public:
11841181
VPInstruction(unsigned Opcode, ArrayRef<VPValue *> Operands, DebugLoc DL,
11851182
const Twine &Name = "")

llvm/lib/Transforms/Vectorize/VPlanSLP.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -461,7 +461,6 @@ VPInstruction *VPlanSlp::buildGraph(ArrayRef<VPValue *> Values) {
461461
assert(CombinedOperands.size() > 0 && "Need more some operands");
462462
auto *Inst = cast<VPInstruction>(Values[0])->getUnderlyingInstr();
463463
auto *VPI = new VPInstruction(Opcode, CombinedOperands, Inst->getDebugLoc());
464-
VPI->setUnderlyingInstr(Inst);
465464

466465
LLVM_DEBUG(dbgs() << "Create VPInstruction " << *VPI << " "
467466
<< *cast<VPInstruction>(Values[0]) << "\n");

0 commit comments

Comments
 (0)