Lines Matching refs:BI

215     BlockInfo BI;  in calcLiveBlockInfo()  local
216 BI.MBB = &*MFI; in calcLiveBlockInfo()
218 std::tie(Start, Stop) = LIS.getSlotIndexes()->getMBBRange(BI.MBB); in calcLiveBlockInfo()
225 ThroughBlocks.set(BI.MBB->getNumber()); in calcLiveBlockInfo()
231 BI.FirstInstr = *UseI; in calcLiveBlockInfo()
232 assert(BI.FirstInstr >= Start); in calcLiveBlockInfo()
235 BI.LastInstr = UseI[-1]; in calcLiveBlockInfo()
236 assert(BI.LastInstr < Stop); in calcLiveBlockInfo()
239 BI.LiveIn = LVI->start <= Start; in calcLiveBlockInfo()
242 if (!BI.LiveIn) { in calcLiveBlockInfo()
244 assert(LVI->start == BI.FirstInstr && "First instr should be a def"); in calcLiveBlockInfo()
245 BI.FirstDef = BI.FirstInstr; in calcLiveBlockInfo()
249 BI.LiveOut = true; in calcLiveBlockInfo()
253 BI.LiveOut = false; in calcLiveBlockInfo()
254 BI.LastInstr = LastStop; in calcLiveBlockInfo()
264 BI.LiveOut = false; in calcLiveBlockInfo()
265 UseBlocks.push_back(BI); in calcLiveBlockInfo()
269 BI.LiveIn = false; in calcLiveBlockInfo()
270 BI.LiveOut = true; in calcLiveBlockInfo()
271 BI.FirstInstr = BI.FirstDef = LVI->start; in calcLiveBlockInfo()
276 if (!BI.FirstDef) in calcLiveBlockInfo()
277 BI.FirstDef = LVI->start; in calcLiveBlockInfo()
280 UseBlocks.push_back(BI); in calcLiveBlockInfo()
1576 bool SplitAnalysis::shouldSplitSingleBlock(const BlockInfo &BI, in shouldSplitSingleBlock() argument
1579 if (!BI.isOneInstr()) in shouldSplitSingleBlock()
1585 if (BI.LiveIn && BI.LiveOut) in shouldSplitSingleBlock()
1588 if (LIS.getInstructionFromIndex(BI.FirstInstr)->isCopyLike()) in shouldSplitSingleBlock()
1591 return isOriginalEndpoint(BI.FirstInstr); in shouldSplitSingleBlock()
1594 void SplitEditor::splitSingleBlock(const SplitAnalysis::BlockInfo &BI) { in splitSingleBlock() argument
1596 SlotIndex LastSplitPoint = SA.getLastSplitPoint(BI.MBB); in splitSingleBlock()
1597 SlotIndex SegStart = enterIntvBefore(std::min(BI.FirstInstr, in splitSingleBlock()
1599 if (!BI.LiveOut || BI.LastInstr < LastSplitPoint) { in splitSingleBlock()
1600 useIntv(SegStart, leaveIntvAfter(BI.LastInstr)); in splitSingleBlock()
1605 overlapIntv(SegStop, BI.LastInstr); in splitSingleBlock()
1723 void SplitEditor::splitRegInBlock(const SplitAnalysis::BlockInfo &BI, in splitRegInBlock() argument
1726 std::tie(Start, Stop) = LIS.getSlotIndexes()->getMBBRange(BI.MBB); in splitRegInBlock()
1728 LLVM_DEBUG(dbgs() << printMBBReference(*BI.MBB) << " [" << Start << ';' in splitRegInBlock()
1729 << Stop << "), uses " << BI.FirstInstr << '-' in splitRegInBlock()
1730 << BI.LastInstr << ", reg-in " << IntvIn in splitRegInBlock()
1732 << (BI.LiveOut ? ", stack-out" : ", killed in block")); in splitRegInBlock()
1735 assert(BI.LiveIn && "Must be live-in"); in splitRegInBlock()
1738 if (!BI.LiveOut && (!LeaveBefore || LeaveBefore >= BI.LastInstr)) { in splitRegInBlock()
1746 useIntv(Start, BI.LastInstr); in splitRegInBlock()
1750 SlotIndex LSP = SA.getLastSplitPoint(BI.MBB); in splitRegInBlock()
1752 if (!LeaveBefore || LeaveBefore > BI.LastInstr.getBoundaryIndex()) { in splitRegInBlock()
1763 if (BI.LastInstr < LSP) { in splitRegInBlock()
1766 SlotIndex Idx = leaveIntvAfter(BI.LastInstr); in splitRegInBlock()
1773 overlapIntv(Idx, BI.LastInstr); in splitRegInBlock()
1787 if (!BI.LiveOut || BI.LastInstr < LSP) { in splitRegInBlock()
1793 SlotIndex To = leaveIntvAfter(BI.LastInstr); in splitRegInBlock()
1808 overlapIntv(To, BI.LastInstr); in splitRegInBlock()
1816 void SplitEditor::splitRegOutBlock(const SplitAnalysis::BlockInfo &BI, in splitRegOutBlock() argument
1819 std::tie(Start, Stop) = LIS.getSlotIndexes()->getMBBRange(BI.MBB); in splitRegOutBlock()
1821 LLVM_DEBUG(dbgs() << printMBBReference(*BI.MBB) << " [" << Start << ';' in splitRegOutBlock()
1822 << Stop << "), uses " << BI.FirstInstr << '-' in splitRegOutBlock()
1823 << BI.LastInstr << ", reg-out " << IntvOut in splitRegOutBlock()
1825 << (BI.LiveIn ? ", stack-in" : ", defined in block")); in splitRegOutBlock()
1827 SlotIndex LSP = SA.getLastSplitPoint(BI.MBB); in splitRegOutBlock()
1830 assert(BI.LiveOut && "Must be live-out"); in splitRegOutBlock()
1833 if (!BI.LiveIn && (!EnterAfter || EnterAfter <= BI.FirstInstr)) { in splitRegOutBlock()
1841 useIntv(BI.FirstInstr, Stop); in splitRegOutBlock()
1845 if (!EnterAfter || EnterAfter < BI.FirstInstr.getBaseIndex()) { in splitRegOutBlock()
1853 SlotIndex Idx = enterIntvBefore(std::min(LSP, BI.FirstInstr)); in splitRegOutBlock()
1874 SlotIndex From = enterIntvBefore(std::min(Idx, BI.FirstInstr)); in splitRegOutBlock()