Lines Matching refs:Dist
123 bool noUseAfterLastDef(Register Reg, unsigned Dist, unsigned &LastDef);
126 MachineInstr *MI, unsigned Dist);
129 unsigned RegBIdx, unsigned RegCIdx, unsigned Dist);
135 Register RegB, unsigned Dist);
137 bool isDefTooClose(Register Reg, unsigned Dist, MachineInstr *MI);
147 unsigned Dist, bool shouldOnlyCommute);
153 unsigned Dist);
162 void processTiedPairs(MachineInstr *MI, TiedPairList&, unsigned &Dist);
244 bool TwoAddressInstructionPass::noUseAfterLastDef(Register Reg, unsigned Dist, in noUseAfterLastDef() argument
247 unsigned LastUse = Dist; in noUseAfterLastDef()
261 return !(LastUse > LastDef && LastUse < Dist); in noUseAfterLastDef()
441 unsigned Dist) { in isProfitableToCommute() argument
500 if (!noUseAfterLastDef(RegC, Dist, LastDefC)) in isProfitableToCommute()
506 if (!noUseAfterLastDef(RegB, Dist, LastDefB)) in isProfitableToCommute()
546 unsigned Dist) { in commuteInstruction() argument
592 Register RegA, Register RegB, unsigned Dist) { in convertInstTo3Addr() argument
627 DistanceMap.insert(std::make_pair(NewMI, Dist)); in convertInstTo3Addr()
889 bool TwoAddressInstructionPass::isDefTooClose(Register Reg, unsigned Dist, in isDefTooClose() argument
900 assert(Dist > DefDist && "Visited def already?"); in isDefTooClose()
901 if (TII->getInstrLatency(InstrItins, DefMI) > (Dist - DefDist)) in isDefTooClose()
1068 unsigned Dist) { in tryInstructionCommute() argument
1095 isProfitableToCommute(DstOpReg, BaseOpReg, OtherOpReg, MI, Dist)) { in tryInstructionCommute()
1102 Dist)) { in tryInstructionCommute()
1133 unsigned Dist, bool shouldOnlyCommute) { in tryInstructionTransform() argument
1147 bool Commuted = tryInstructionCommute(&MI, DstIdx, SrcIdx, regBKilled, Dist); in tryInstructionTransform()
1182 if (convertInstTo3Addr(mi, nmi, regA, regB, Dist)) { in tryInstructionTransform()
1250 tryInstructionTransform(NewMI, mi, NewSrcIdx, NewDstIdx, Dist, true); in tryInstructionTransform()
1364 unsigned &Dist) { in processTiedPairs() argument
1431 DistanceMap.insert(std::make_pair(&*PrevMI, Dist)); in processTiedPairs()
1432 DistanceMap[MI] = ++Dist; in processTiedPairs()
1557 unsigned Dist = 0; in runOnMachineFunction() local
1576 DistanceMap.insert(std::make_pair(&*mi, ++Dist)); in runOnMachineFunction()
1603 tryInstructionTransform(mi, nmi, SrcIdx, DstIdx, Dist, false)) { in runOnMachineFunction()
1615 processTiedPairs(&*mi, TO.second, Dist); in runOnMachineFunction()