Lines Matching refs:MachineBasicBlock

67     unsigned postOffset(const MachineBasicBlock &MBB) const {  in postOffset()
95 MachineBasicBlock *createNewBlockAfter(MachineBasicBlock &BB);
97 MachineBasicBlock *splitBlockBeforeInstr(MachineInstr &MI,
98 MachineBasicBlock *DestBB);
99 void adjustBlockOffsets(MachineBasicBlock &Start);
100 bool isBlockInRange(const MachineInstr &MI, const MachineBasicBlock &BB) const;
104 uint64_t computeBlockSize(const MachineBasicBlock &MBB) const;
131 for (MachineBasicBlock &MBB : *MF) { in INITIALIZE_PASS()
163 for (MachineBasicBlock &MBB : *MF) in scanFunction()
171 uint64_t BranchRelaxation::computeBlockSize(const MachineBasicBlock &MBB) const { in computeBlockSize()
182 const MachineBasicBlock *MBB = MI.getParent(); in getInstrOffset()
190 for (MachineBasicBlock::const_iterator I = MBB->begin(); &*I != &MI; ++I) { in getInstrOffset()
198 void BranchRelaxation::adjustBlockOffsets(MachineBasicBlock &Start) { in adjustBlockOffsets()
213 MachineBasicBlock *BranchRelaxation::createNewBlockAfter(MachineBasicBlock &BB) { in createNewBlockAfter()
215 MachineBasicBlock *NewBB = in createNewBlockAfter()
228 MachineBasicBlock *BranchRelaxation::splitBlockBeforeInstr(MachineInstr &MI, in splitBlockBeforeInstr()
229 MachineBasicBlock *DestBB) { in splitBlockBeforeInstr()
230 MachineBasicBlock *OrigBB = MI.getParent(); in splitBlockBeforeInstr()
233 MachineBasicBlock *NewBB = in splitBlockBeforeInstr()
284 const MachineInstr &MI, const MachineBasicBlock &DestBB) const { in isBlockInRange()
305 MachineBasicBlock *MBB = MI.getParent(); in fixupConditionalBranch()
306 MachineBasicBlock *TBB = nullptr, *FBB = nullptr; in fixupConditionalBranch()
307 MachineBasicBlock *NewBB = nullptr; in fixupConditionalBranch()
310 auto insertUncondBranch = [&](MachineBasicBlock *MBB, in fixupConditionalBranch()
311 MachineBasicBlock *DestBB) { in fixupConditionalBranch()
317 auto insertBranch = [&](MachineBasicBlock *MBB, MachineBasicBlock *TBB, in fixupConditionalBranch()
318 MachineBasicBlock *FBB, in fixupConditionalBranch()
325 auto removeBranch = [&](MachineBasicBlock *MBB) { in fixupConditionalBranch()
332 auto finalizeBlockChanges = [&](MachineBasicBlock *MBB, in fixupConditionalBranch()
333 MachineBasicBlock *NewBB) { in fixupConditionalBranch()
387 MachineBasicBlock &NextBB = *std::next(MachineFunction::iterator(MBB)); in fixupConditionalBranch()
442 MachineBasicBlock *MBB = MI.getParent(); in fixupUnconditionalBranch()
445 MachineBasicBlock *DestBB = TII->getBranchDestBlock(MI); in fixupUnconditionalBranch()
454 MachineBasicBlock *BranchBB = MBB; in fixupUnconditionalBranch()
462 for (const MachineBasicBlock *Succ : MBB->successors()) { in fixupUnconditionalBranch()
463 for (const MachineBasicBlock::RegisterMaskPair &LiveIn : Succ->liveins()) in fixupUnconditionalBranch()
487 MachineBasicBlock &MBB = *I; in relaxBranchInstructions()
490 MachineBasicBlock::iterator Last = MBB.getLastNonDebugInstr(); in relaxBranchInstructions()
502 if (MachineBasicBlock *DestBB = TII->getBranchDestBlock(*Last)) { in relaxBranchInstructions()
512 MachineBasicBlock::iterator Next; in relaxBranchInstructions()
513 for (MachineBasicBlock::iterator J = MBB.getFirstTerminator(); in relaxBranchInstructions()
519 MachineBasicBlock *DestBB = TII->getBranchDestBlock(MI); in relaxBranchInstructions()