Lines Matching defs:BI
183 BlockInfo BI;
184 BI.MBB = &*MFI;
186 std::tie(Start, Stop) = LIS.getSlotIndexes()->getMBBRange(BI.MBB);
193 ThroughBlocks.set(BI.MBB->getNumber());
200 BI.FirstInstr = *UseI;
201 assert(BI.FirstInstr >= Start);
204 BI.LastInstr = UseI[-1];
205 assert(BI.LastInstr < Stop);
208 BI.LiveIn = LVI->start <= Start;
211 if (!BI.LiveIn) {
213 assert(LVI->start == BI.FirstInstr && "First instr should be a def");
214 BI.FirstDef = BI.FirstInstr;
218 BI.LiveOut = true;
222 BI.LiveOut = false;
223 BI.LastInstr = LastStop;
233 BI.LiveOut = false;
234 UseBlocks.push_back(BI);
237 // Set up BI for the live-out part.
238 BI.LiveIn = false;
239 BI.LiveOut = true;
240 BI.FirstInstr = BI.FirstDef = LVI->start;
245 if (!BI.FirstDef)
246 BI.FirstDef = LVI->start;
249 UseBlocks.push_back(BI);
1111 bool SplitAnalysis::shouldSplitSingleBlock(const BlockInfo &BI,
1114 if (!BI.isOneInstr())
1120 if (BI.LiveIn && BI.LiveOut)
1123 if (LIS.getInstructionFromIndex(BI.FirstInstr)->isCopyLike())
1126 return isOriginalEndpoint(BI.FirstInstr);
1129 void SplitEditor::splitSingleBlock(const SplitAnalysis::BlockInfo &BI) {
1131 SlotIndex LastSplitPoint = SA.getLastSplitPoint(BI.MBB->getNumber());
1132 SlotIndex SegStart = enterIntvBefore(std::min(BI.FirstInstr,
1134 if (!BI.LiveOut || BI.LastInstr < LastSplitPoint) {
1135 useIntv(SegStart, leaveIntvAfter(BI.LastInstr));
1140 overlapIntv(SegStop, BI.LastInstr);
1260 void SplitEditor::splitRegInBlock(const SplitAnalysis::BlockInfo &BI,
1263 std::tie(Start, Stop) = LIS.getSlotIndexes()->getMBBRange(BI.MBB);
1265 DEBUG(dbgs() << "BB#" << BI.MBB->getNumber() << " [" << Start << ';' << Stop
1266 << "), uses " << BI.FirstInstr << '-' << BI.LastInstr
1268 << (BI.LiveOut ? ", stack-out" : ", killed in block"));
1271 assert(BI.LiveIn && "Must be live-in");
1274 if (!BI.LiveOut && (!LeaveBefore || LeaveBefore >= BI.LastInstr)) {
1282 useIntv(Start, BI.LastInstr);
1286 SlotIndex LSP = SA.getLastSplitPoint(BI.MBB->getNumber());
1288 if (!LeaveBefore || LeaveBefore > BI.LastInstr.getBoundaryIndex()) {
1299 if (BI.LastInstr < LSP) {
1302 SlotIndex Idx = leaveIntvAfter(BI.LastInstr);
1309 overlapIntv(Idx, BI.LastInstr);
1323 if (!BI.LiveOut || BI.LastInstr < LSP) {
1329 SlotIndex To = leaveIntvAfter(BI.LastInstr);
1344 overlapIntv(To, BI.LastInstr);
1352 void SplitEditor::splitRegOutBlock(const SplitAnalysis::BlockInfo &BI,
1355 std::tie(Start, Stop) = LIS.getSlotIndexes()->getMBBRange(BI.MBB);
1357 DEBUG(dbgs() << "BB#" << BI.MBB->getNumber() << " [" << Start << ';' << Stop
1358 << "), uses " << BI.FirstInstr << '-' << BI.LastInstr
1360 << (BI.LiveIn ? ", stack-in" : ", defined in block"));
1362 SlotIndex LSP = SA.getLastSplitPoint(BI.MBB->getNumber());
1365 assert(BI.LiveOut && "Must be live-out");
1368 if (!BI.LiveIn && (!EnterAfter || EnterAfter <= BI.FirstInstr)) {
1376 useIntv(BI.FirstInstr, Stop);
1380 if (!EnterAfter || EnterAfter < BI.FirstInstr.getBaseIndex()) {
1388 SlotIndex Idx = enterIntvBefore(std::min(LSP, BI.FirstInstr));
1409 SlotIndex From = enterIntvBefore(std::min(Idx, BI.FirstInstr));