Lines Matching refs:PredBB
84 MachineBasicBlock *PredBB = *PI; in VerifyPHIs() local
88 if (PHIBB == PredBB) { in VerifyPHIs()
96 << PredBB->getNumber() << '\n'; in VerifyPHIs()
304 MachineInstr *MI, MachineBasicBlock *TailBB, MachineBasicBlock *PredBB, in processPHI() argument
309 unsigned SrcOpIdx = getPHISrcRegOpIdx(MI, PredBB); in processPHI()
321 addSSAUpdateEntry(DefReg, NewDef, PredBB); in processPHI()
336 MachineInstr *MI, MachineBasicBlock *TailBB, MachineBasicBlock *PredBB, in duplicateInstruction() argument
355 addSSAUpdateEntry(Reg, NewReg, PredBB); in duplicateInstruction()
396 BuildMI(*PredBB, MI, MI->getDebugLoc(), in duplicateInstruction()
414 PredBB->insert(PredBB->instr_end(), NewMI); in duplicateInstruction()
628 for (MachineBasicBlock *PredBB : BB.predecessors()) { in canCompletelyDuplicateBB()
629 if (PredBB->succ_size() > 1) in canCompletelyDuplicateBB()
634 if (TII->analyzeBranch(*PredBB, PredTBB, PredFBB, PredCond, true)) in canCompletelyDuplicateBB()
655 MachineBasicBlock *PredBB = *PI; in duplicateSimpleBB() local
657 if (PredBB->hasEHPadSuccessor()) in duplicateSimpleBB()
660 if (bothUsedInPHI(*PredBB, Succs)) in duplicateSimpleBB()
665 if (TII->analyzeBranch(*PredBB, PredTBB, PredFBB, PredCond, true)) in duplicateSimpleBB()
669 DEBUG(dbgs() << "\nTail-duplicating into PredBB: " << *PredBB in duplicateSimpleBB()
673 MachineBasicBlock *NextBB = &*std::next(PredBB->getIterator()); in duplicateSimpleBB()
703 TII->RemoveBranch(*PredBB); in duplicateSimpleBB()
705 if (!PredBB->isSuccessor(NewTarget)) in duplicateSimpleBB()
706 PredBB->replaceSuccessor(TailBB, NewTarget); in duplicateSimpleBB()
708 PredBB->removeSuccessor(TailBB, true); in duplicateSimpleBB()
709 assert(PredBB->succ_size() <= 1); in duplicateSimpleBB()
713 TII->InsertBranch(*PredBB, PredTBB, PredFBB, PredCond, DebugLoc()); in duplicateSimpleBB()
715 TDBBs.push_back(PredBB); in duplicateSimpleBB()
743 MachineBasicBlock *PredBB = *PI; in tailDuplicate() local
745 assert(TailBB != PredBB && in tailDuplicate()
748 if (PredBB->succ_size() > 1) in tailDuplicate()
753 if (TII->analyzeBranch(*PredBB, PredTBB, PredFBB, PredCond, true)) in tailDuplicate()
758 if (PredBB->isLayoutSuccessor(TailBB) && PredBB->canFallThrough()) in tailDuplicate()
761 DEBUG(dbgs() << "\nTail-duplicating into PredBB: " << *PredBB in tailDuplicate()
764 TDBBs.push_back(PredBB); in tailDuplicate()
767 TII->RemoveBranch(*PredBB); in tailDuplicate()
781 processPHI(MI, TailBB, PredBB, LocalVRMap, CopyInfos, UsedByPhi, true); in tailDuplicate()
785 duplicateInstruction(MI, TailBB, PredBB, MF, LocalVRMap, UsedByPhi); in tailDuplicate()
788 appendCopies(PredBB, CopyInfos, Copies); in tailDuplicate()
791 TII->analyzeBranch(*PredBB, PredTBB, PredFBB, PredCond, true); in tailDuplicate()
796 PredBB->removeSuccessor(PredBB->succ_begin()); in tailDuplicate()
797 assert(PredBB->succ_empty() && in tailDuplicate()
802 PredBB->addSuccessor(*I, MBPI->getEdgeProbability(TailBB, I)); in tailDuplicate()
880 MachineBasicBlock *PredBB = *PI; in tailDuplicate() local
881 if (std::find(TDBBs.begin(), TDBBs.end(), PredBB) != TDBBs.end()) in tailDuplicate()
885 if (PredBB->succ_size() != 1) in tailDuplicate()
896 processPHI(MI, TailBB, PredBB, LocalVRMap, CopyInfos, UsedByPhi, false); in tailDuplicate()
898 appendCopies(PredBB, CopyInfos, Copies); in tailDuplicate()