• Home
  • Raw
  • Download

Lines Matching refs:Phi

410                              unsigned PhiNum, MachineInstr *Phi,
672 bool isLoopCarried(SwingSchedulerDAG *SSD, MachineInstr &Phi);
917 static void getPhiRegs(MachineInstr &Phi, MachineBasicBlock *Loop, in getPhiRegs() argument
919 assert(Phi.isPHI() && "Expecting a Phi."); in getPhiRegs()
923 for (unsigned i = 1, e = Phi.getNumOperands(); i != e; i += 2) in getPhiRegs()
924 if (Phi.getOperand(i + 1).getMBB() != Loop) in getPhiRegs()
925 InitVal = Phi.getOperand(i).getReg(); in getPhiRegs()
926 else if (Phi.getOperand(i + 1).getMBB() == Loop) in getPhiRegs()
927 LoopVal = Phi.getOperand(i).getReg(); in getPhiRegs()
933 static unsigned getInitPhiReg(MachineInstr &Phi, MachineBasicBlock *LoopBB) { in getInitPhiReg() argument
934 for (unsigned i = 1, e = Phi.getNumOperands(); i != e; i += 2) in getInitPhiReg()
935 if (Phi.getOperand(i + 1).getMBB() != LoopBB) in getInitPhiReg()
936 return Phi.getOperand(i).getReg(); in getInitPhiReg()
941 static unsigned getLoopPhiReg(MachineInstr &Phi, MachineBasicBlock *LoopBB) { in getLoopPhiReg() argument
942 for (unsigned i = 1, e = Phi.getNumOperands(); i != e; i += 2) in getLoopPhiReg()
943 if (Phi.getOperand(i + 1).getMBB() == LoopBB) in getLoopPhiReg()
944 return Phi.getOperand(i).getReg(); in getLoopPhiReg()
3248 unsigned CurStageNum, unsigned PhiNum, MachineInstr *Phi, unsigned OldReg, in rewriteScheduledInstr() argument
3251 int StagePhi = Schedule.stageScheduled(getSUnit(Phi)) + PhiNum; in rewriteScheduledInstr()
3263 if (!Phi->isPHI() && UseMI->getOperand(0).getReg() == NewReg) in rewriteScheduledInstr()
3275 if (StagePhi == StageSched && Phi->isPHI()) { in rewriteScheduledInstr()
3276 int CyclePhi = Schedule.cycleScheduled(getSUnit(Phi)); in rewriteScheduledInstr()
3279 else if (PrevReg && !Schedule.isLoopCarried(this, *Phi) && in rewriteScheduledInstr()
3288 !Schedule.isLoopCarried(this, *Phi)) in rewriteScheduledInstr()
3290 if (StagePhi > StageSched && Phi->isPHI()) in rewriteScheduledInstr()
3292 if (!InProlog && !Phi->isPHI() && StagePhi < StageSched) in rewriteScheduledInstr()
3323 MachineInstr *Phi = MRI.getVRegDef(BaseReg); in canUseLastOffsetValue() local
3324 if (!Phi || !Phi->isPHI()) in canUseLastOffsetValue()
3327 unsigned PrevReg = getLoopPhiReg(*Phi, MI->getParent()); in canUseLastOffsetValue()
3766 bool SMSchedule::isLoopCarried(SwingSchedulerDAG *SSD, MachineInstr &Phi) { in isLoopCarried() argument
3767 if (!Phi.isPHI()) in isLoopCarried()
3769 assert(Phi.isPHI() && "Expecing a Phi."); in isLoopCarried()
3770 SUnit *DefSU = SSD->getSUnit(&Phi); in isLoopCarried()
3776 getPhiRegs(Phi, Phi.getParent(), InitVal, LoopVal); in isLoopCarried()
3801 MachineInstr *Phi = MRI.getVRegDef(MO.getReg()); in isLoopCarriedDefOfUse() local
3802 if (!Phi || !Phi->isPHI() || Phi->getParent() != Def->getParent()) in isLoopCarriedDefOfUse()
3804 if (!isLoopCarried(SSD, *Phi)) in isLoopCarriedDefOfUse()
3806 unsigned LoopReg = getLoopPhiReg(*Phi, Phi->getParent()); in isLoopCarriedDefOfUse()