Lines Matching defs:DestBB
118 BasicBlock *DestBB = TI->getSuccessor(SuccNum);
122 if (DestBB->isEHPad()) return nullptr;
125 isa<UnreachableInst>(DestBB->getFirstNonPHIOrDbgOrLifetime()))
138 // DestBB *and* the only edge into DestBB from outside of TIL is that of
141 // second isn't true, then DestBB was not in LoopSimplify form prior to
145 for (BasicBlock *P : predecessors(DestBB)) {
173 DestBB->getName() +
176 BranchInst *NewBI = BranchInst::Create(DestBB, NewBB);
187 // If there are any PHI nodes in DestBB, we need to update them so that they
191 for (BasicBlock::iterator I = DestBB->begin(); isa<PHINode>(I); ++I) {
208 // If there are any other edges from TIBB to DestBB, update those to go
210 // reducing the number of phi entries in the DestBB if relevant).
213 if (TI->getSuccessor(i) != DestBB) continue;
215 // Remove an entry for TIBB from DestBB phi nodes.
216 DestBB->removePredecessor(TIBB, Options.KeepOneInputPHIs);
218 // We found another edge to DestBB, go to NewBB instead.
229 DestBB, NewBB, {TIBB}, Options.MergeIdenticalEdges);
238 // TIBB -------\\------> DestBB
240 // First, inform the DT about the new path from TIBB to DestBB via NewBB,
241 // then delete the old edge from TIBB to DestBB. By doing this in that order
242 // DestBB stays reachable in the DT the whole time and its subtree doesn't
246 Updates.push_back({DominatorTree::Insert, NewBB, DestBB});
247 if (!llvm::is_contained(successors(TIBB), DestBB))
248 Updates.push_back({DominatorTree::Delete, TIBB, DestBB});
261 if (Loop *DestLoop = LI->getLoopFor(DestBB)) {
276 assert(DestLoop->getHeader() == DestBB &&
283 // If TIBB is in a loop and DestBB is outside of that loop, we may need
285 if (!TIL->contains(DestBB)) {
291 createPHIsForSplitLoopExit(TIBB, NewBB, DestBB);
295 assert(!DestBB->isEHPad() && "We don't split edges to EH pads!");
297 DestBB, LoopPreds, "split", DT, LI, MSSAU, Options.PreserveLCSSA);
299 createPHIsForSplitLoopExit(LoopPreds, NewExitBB, DestBB);