[llvm] [VPlan] Remove ResumePhi opcode, use regular PHI instead (NFC). (PR #140405)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Wed May 28 08:37:18 PDT 2025
================
@@ -1095,11 +1079,19 @@ void VPInstructionWithType::print(raw_ostream &O, const Twine &Indent,
void VPPhi::execute(VPTransformState &State) {
State.setDebugLocFrom(getDebugLoc());
- BasicBlock *VectorPH = State.CFG.VPBB2IRBB.at(getIncomingBlock(0));
- Value *Start = State.get(getIncomingValue(0), VPLane(0));
- PHINode *Phi = State.Builder.CreatePHI(Start->getType(), 2, getName());
- Phi->addIncoming(Start, VectorPH);
- State.set(this, Phi, VPLane(0));
+ PHINode *NewPhi = State.Builder.CreatePHI(
+ State.TypeAnalysis.inferScalarType(this), 2, getName());
+ // TODO: Fixup incoming values once other recipes are enabled.
----------------
fhahn wrote:
Update, although the case which needs fixing up later are the phis in the header blocks, for which the latch value has not yet been generated; the phis in the scalar preheader will only execute once all incoming values have been generated.
https://github.com/llvm/llvm-project/pull/140405
More information about the llvm-commits
mailing list