/external/llvm-project/llvm/unittests/IR/ |
D | CFGBuilder.cpp | 43 if (isa<UnreachableInst>(From->getTerminator())) in ConnectBlocks() 44 From->getTerminator()->eraseFromParent(); in ConnectBlocks() 45 if (!From->getTerminator()) { in ConnectBlocks() 51 SwitchInst *SI = cast<SwitchInst>(From->getTerminator()); in ConnectBlocks() 62 SwitchInst *SI = cast<SwitchInst>(From->getTerminator()); in DisconnectBlocks() 173 EXPECT_TRUE(isa<SwitchInst>(B.getOrAddBlock("entry")->getTerminator())); in TEST() 174 EXPECT_TRUE(isa<SwitchInst>(B.getOrAddBlock("a")->getTerminator())); in TEST() 175 EXPECT_TRUE(isa<UnreachableInst>(B.getOrAddBlock("b")->getTerminator())); in TEST() 176 EXPECT_TRUE(isa<SwitchInst>(B.getOrAddBlock("d")->getTerminator())); in TEST() 178 auto *DSwitch = cast<SwitchInst>(B.getOrAddBlock("d")->getTerminator()); in TEST() [all …]
|
/external/llvm-project/llvm/unittests/Analysis/ |
D | DomTreeUpdaterTest.cpp | 71 SwitchInst *SI = dyn_cast<SwitchInst>(BB0->getTerminator()); in TEST() 91 EXPECT_EQ(BB0->getTerminator()->getNumSuccessors(), 3u); in TEST() 99 EXPECT_EQ(BB0->getTerminator()->getNumSuccessors(), 2u); in TEST() 103 ASSERT_FALSE(isa<UnreachableInst>(BB3->getTerminator())); in TEST() 194 EXPECT_EQ(NewEntry->getTerminator()->getNumSuccessors(), 1u); in TEST() 195 NewEntry->getTerminator()->eraseFromParent(); in TEST() 197 EXPECT_EQ(BB0->getTerminator()->getNumSuccessors(), 1u); in TEST() 207 ASSERT_FALSE(isa<UnreachableInst>(BB0->getTerminator())); in TEST() 271 EXPECT_EQ(BB0->getTerminator()->getNumSuccessors(), 4u); in TEST() 272 BB0->getTerminator()->eraseFromParent(); in TEST() [all …]
|
/external/llvm/lib/Transforms/Utils/ |
D | FlattenCFG.cpp | 139 BranchInst *PBI = dyn_cast<BranchInst>(Pred->getTerminator()); in FlattenParallelAndOr() 211 BranchInst *BPS = dyn_cast<BranchInst>(PS->getTerminator()); in FlattenParallelAndOr() 222 TerminatorInst *TBB = LastCondBlock->getTerminator(); in FlattenParallelAndOr() 225 BranchInst *PBI1 = dyn_cast<BranchInst>(PS1->getTerminator()); in FlattenParallelAndOr() 226 BranchInst *PBI2 = dyn_cast<BranchInst>(PS2->getTerminator()); in FlattenParallelAndOr() 231 (PS1->getTerminator()->getSuccessor(0) != PS2)) { in FlattenParallelAndOr() 234 (PS2->getTerminator()->getSuccessor(0) != PS1)) in FlattenParallelAndOr() 242 BranchInst *BI = dyn_cast<BranchInst>(CurrBlock->getTerminator()); in FlattenParallelAndOr() 269 BranchInst *PBI = dyn_cast<BranchInst>(FirstCondBlock->getTerminator()); in FlattenParallelAndOr() 280 PBI = cast<BranchInst>(FirstCondBlock->getTerminator()); in FlattenParallelAndOr() [all …]
|
D | BasicBlockUtils.cpp | 38 TerminatorInst *BBTerm = BB->getTerminator(); in DeleteDeadBlock() 108 if (PredBB->getTerminator()->isExceptional()) in MergeBlockIntoPredecessor() 215 TerminatorInst *LatchTerm = BB->getTerminator(); in SplitEdge() 232 assert(BB->getTerminator()->getNumSuccessors() == 1 && in SplitEdge() 234 return SplitBlock(BB, BB->getTerminator(), DT, LI); in SplitEdge() 242 TerminatorInst *TI = BB.getTerminator(); in SplitAllCriticalEdges() 448 assert(!isa<IndirectBrInst>(Preds[i]->getTerminator()) && in SplitBlockPredecessors() 450 Preds[i]->getTerminator()->replaceUsesOfWith(BB, NewBB); in SplitBlockPredecessors() 498 assert(!isa<IndirectBrInst>(Preds[i]->getTerminator()) && in SplitLandingPadPredecessors() 500 Preds[i]->getTerminator()->replaceUsesOfWith(OrigBB, NewBB1); in SplitLandingPadPredecessors() [all …]
|
D | LoopUnrollRuntime.cpp | 117 Instruction *InsertPt = PrologExit->getTerminator(); in ConnectProlog() 247 Instruction *InsertPt = NewExit->getTerminator(); in ConnectEpilog() 307 InsertTop->getTerminator()->setSuccessor(0, NewBB); in CloneLoopBlocks() 313 VMap.erase((*BB)->getTerminator()); in CloneLoopBlocks() 315 BranchInst *LatchBR = cast<BranchInst>(NewBB->getTerminator()); in CloneLoopBlocks() 470 BranchInst *PreHeaderBR = cast<BranchInst>(PreHeader->getTerminator()); in UnrollRuntimeLoopRemainder() 506 NewPreHeader = SplitBlock(PreHeader, PreHeader->getTerminator(), DT, LI); in UnrollRuntimeLoopRemainder() 513 EpilogPreHeader = SplitBlock(NewExit, NewExit->getTerminator(), DT, LI); in UnrollRuntimeLoopRemainder() 520 PrologExit = SplitBlock(PrologPreHeader, PrologPreHeader->getTerminator(), in UnrollRuntimeLoopRemainder() 524 NewPreHeader = SplitBlock(PrologExit, PrologExit->getTerminator(), DT, LI); in UnrollRuntimeLoopRemainder() [all …]
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Transforms/Utils/ |
D | FlattenCFG.cpp | 151 BranchInst *PBI = dyn_cast<BranchInst>(Pred->getTerminator()); in FlattenParallelAndOr() 223 BranchInst *BPS = dyn_cast<BranchInst>(PS->getTerminator()); in FlattenParallelAndOr() 234 Instruction *TBB = LastCondBlock->getTerminator(); in FlattenParallelAndOr() 237 BranchInst *PBI1 = dyn_cast<BranchInst>(PS1->getTerminator()); in FlattenParallelAndOr() 238 BranchInst *PBI2 = dyn_cast<BranchInst>(PS2->getTerminator()); in FlattenParallelAndOr() 243 (PS1->getTerminator()->getSuccessor(0) != PS2)) { in FlattenParallelAndOr() 246 (PS2->getTerminator()->getSuccessor(0) != PS1)) in FlattenParallelAndOr() 254 auto *BI = cast<BranchInst>(CurrBlock->getTerminator()); in FlattenParallelAndOr() 281 BranchInst *PBI = cast<BranchInst>(FirstCondBlock->getTerminator()); in FlattenParallelAndOr() 292 PBI = cast<BranchInst>(FirstCondBlock->getTerminator()); in FlattenParallelAndOr() [all …]
|
D | BasicBlockUtils.cpp | 82 isa<UnreachableInst>(BB->getTerminator()) && in DetatchDeadBlocks() 185 if (PredBB->getTerminator()->isExceptionalTerminator()) in MergeBlockIntoPredecessor() 198 if (!(PredBB_BI = dyn_cast<BranchInst>(PredBB->getTerminator()))) in MergeBlockIntoPredecessor() 200 BranchInst *BB_JmpI = dyn_cast<BranchInst>(BB->getTerminator()); in MergeBlockIntoPredecessor() 246 Instruction *PTI = PredBB->getTerminator(); in MergeBlockIntoPredecessor() 247 Instruction *STI = BB->getTerminator(); in MergeBlockIntoPredecessor() 281 MSSAU->getMemorySSA()->getMemoryAccess(PredBB->getTerminator()))) in MergeBlockIntoPredecessor() 305 isa<UnreachableInst>(BB->getTerminator()) && in MergeBlockIntoPredecessor() 479 Instruction *LatchTerm = BB->getTerminator(); in SplitEdge() 497 assert(BB->getTerminator()->getNumSuccessors() == 1 && in SplitEdge() [all …]
|
D | LoopUnrollRuntime.cpp | 149 Instruction *InsertPt = PrologExit->getTerminator(); in ConnectProlog() 271 Instruction *InsertPt = NewExit->getTerminator(); in ConnectEpilog() 334 InsertTop->getTerminator()->setSuccessor(0, NewBB); in CloneLoopBlocks() 351 VMap.erase((*BB)->getTerminator()); in CloneLoopBlocks() 353 BranchInst *LatchBR = cast<BranchInst>(NewBB->getTerminator()); in CloneLoopBlocks() 568 BranchInst *LatchBR = cast<BranchInst>(Latch->getTerminator()); in UnrollRuntimeLoopRemainder() 636 BranchInst *PreHeaderBR = cast<BranchInst>(PreHeader->getTerminator()); in UnrollRuntimeLoopRemainder() 671 NewPreHeader = SplitBlock(PreHeader, PreHeader->getTerminator(), DT, LI); in UnrollRuntimeLoopRemainder() 680 auto *NewExitTerminator = NewExit->getTerminator(); in UnrollRuntimeLoopRemainder() 681 NewExitTerminator->setDebugLoc(Header->getTerminator()->getDebugLoc()); in UnrollRuntimeLoopRemainder() [all …]
|
/external/llvm-project/llvm/lib/Transforms/Utils/ |
D | FlattenCFG.cpp | 151 BranchInst *PBI = dyn_cast<BranchInst>(Pred->getTerminator()); in FlattenParallelAndOr() 223 BranchInst *BPS = dyn_cast<BranchInst>(PS->getTerminator()); in FlattenParallelAndOr() 234 Instruction *TBB = LastCondBlock->getTerminator(); in FlattenParallelAndOr() 237 BranchInst *PBI1 = dyn_cast<BranchInst>(PS1->getTerminator()); in FlattenParallelAndOr() 238 BranchInst *PBI2 = dyn_cast<BranchInst>(PS2->getTerminator()); in FlattenParallelAndOr() 243 (PS1->getTerminator()->getSuccessor(0) != PS2)) { in FlattenParallelAndOr() 246 (PS2->getTerminator()->getSuccessor(0) != PS1)) in FlattenParallelAndOr() 254 auto *BI = cast<BranchInst>(CurrBlock->getTerminator()); in FlattenParallelAndOr() 281 BranchInst *PBI = cast<BranchInst>(FirstCondBlock->getTerminator()); in FlattenParallelAndOr() 292 PBI = cast<BranchInst>(FirstCondBlock->getTerminator()); in FlattenParallelAndOr() [all …]
|
D | BasicBlockUtils.cpp | 82 isa<UnreachableInst>(BB->getTerminator()) && in DetatchDeadBlocks() 186 if (PredBB->getTerminator()->isExceptionalTerminator()) in MergeBlockIntoPredecessor() 199 if (!(PredBB_BI = dyn_cast<BranchInst>(PredBB->getTerminator()))) in MergeBlockIntoPredecessor() 201 BranchInst *BB_JmpI = dyn_cast<BranchInst>(BB->getTerminator()); in MergeBlockIntoPredecessor() 247 Instruction *PTI = PredBB->getTerminator(); in MergeBlockIntoPredecessor() 248 Instruction *STI = BB->getTerminator(); in MergeBlockIntoPredecessor() 282 MSSAU->getMemorySSA()->getMemoryAccess(PredBB->getTerminator()))) in MergeBlockIntoPredecessor() 301 isa<UnreachableInst>(BB->getTerminator()) && in MergeBlockIntoPredecessor() 500 Instruction *LatchTerm = BB->getTerminator(); in SplitEdge() 518 assert(BB->getTerminator()->getNumSuccessors() == 1 && in SplitEdge() [all …]
|
D | LoopUnrollRuntime.cpp | 150 Instruction *InsertPt = PrologExit->getTerminator(); in ConnectProlog() 272 Instruction *InsertPt = NewExit->getTerminator(); in ConnectEpilog() 335 InsertTop->getTerminator()->setSuccessor(0, NewBB); in CloneLoopBlocks() 352 VMap.erase((*BB)->getTerminator()); in CloneLoopBlocks() 354 BranchInst *LatchBR = cast<BranchInst>(NewBB->getTerminator()); in CloneLoopBlocks() 516 cast<BranchInst>(OrigLoop->getLoopLatch()->getTerminator()); in updateLatchBranchWeightsForRemainderLoop() 525 auto *RemainderLatchBR = cast<BranchInst>(Latch->getTerminator()); in updateLatchBranchWeightsForRemainderLoop() 593 BranchInst *LatchBR = cast<BranchInst>(Latch->getTerminator()); in UnrollRuntimeLoopRemainder() 661 BranchInst *PreHeaderBR = cast<BranchInst>(PreHeader->getTerminator()); in UnrollRuntimeLoopRemainder() 697 NewPreHeader = SplitBlock(PreHeader, PreHeader->getTerminator(), DT, LI); in UnrollRuntimeLoopRemainder() [all …]
|
D | BreakCriticalEdges.cpp | 111 assert((SplitBB->getFirstNonPHI() == SplitBB->getTerminator() || in createPHIsForSplitLoopExit() 128 SplitBB->isLandingPad() ? &SplitBB->front() : SplitBB->getTerminator()); in createPHIsForSplitLoopExit() 189 return isa<IndirectBrInst>(Pred->getTerminator()); in SplitCriticalEdge() 352 Instruction *PredTerm = PredBB->getTerminator(); in findIBRPredecessor() 379 auto *IBI = dyn_cast<IndirectBrInst>(BB.getTerminator()); in SplitIndirectBrCriticalEdges() 408 EdgeProbabilities.reserve(Target->getTerminator()->getNumSuccessors()); in SplitIndirectBrCriticalEdges() 409 for (unsigned I = 0, E = Target->getTerminator()->getNumSuccessors(); in SplitIndirectBrCriticalEdges() 437 Src->getTerminator()->replaceUsesOfWith(Target, DirectSucc); in SplitIndirectBrCriticalEdges() 459 assert(&*End == Target->getTerminator() && in SplitIndirectBrCriticalEdges()
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Target/AMDGPU/ |
D | AMDGPUUnifyDivergentExitNodes.cpp | 109 if (!DA.isUniform(Top->getTerminator())) in isUniformlyReached() 181 PN->addIncoming(BB->getTerminator()->getOperand(0), BB); in unifyReturnBlockSet() 184 BB->getTerminator()->eraseFromParent(); in unifyReturnBlockSet() 214 if (isa<ReturnInst>(BB->getTerminator())) { in runOnFunction() 217 } else if (isa<UnreachableInst>(BB->getTerminator())) { in runOnFunction() 220 } else if (BranchInst *BI = dyn_cast<BranchInst>(BB->getTerminator())) { in runOnFunction() 273 BB->getTerminator()->eraseFromParent(); in runOnFunction() 291 BB->getTerminator()->eraseFromParent(); in runOnFunction() 303 UnreachableBlock->getTerminator()->eraseFromParent(); in runOnFunction()
|
/external/llvm-project/llvm/lib/Target/AMDGPU/ |
D | AMDGPUUnifyDivergentExitNodes.cpp | 110 if (!DA.isUniform(Top->getTerminator())) in isUniformlyReached() 182 PN->addIncoming(BB->getTerminator()->getOperand(0), BB); in unifyReturnBlockSet() 185 BB->getTerminator()->eraseFromParent(); in unifyReturnBlockSet() 221 if (isa<ReturnInst>(BB->getTerminator())) { in runOnFunction() 226 } else if (isa<UnreachableInst>(BB->getTerminator())) { in runOnFunction() 229 } else if (BranchInst *BI = dyn_cast<BranchInst>(BB->getTerminator())) { in runOnFunction() 282 BB->getTerminator()->eraseFromParent(); in runOnFunction() 301 BB->getTerminator()->eraseFromParent(); in runOnFunction() 314 UnreachableBlock->getTerminator()->eraseFromParent(); in runOnFunction()
|
/external/llvm/tools/llvm-stress/ |
D | llvm-stress.cpp | 302 Value *V = new LoadInst(Ptr, "L", BB->getTerminator()); in Act() 321 new StoreInst(Val, Ptr, BB->getTerminator()); in Act() 343 Instruction* Term = BB->getTerminator(); in Act() 433 "E", BB->getTerminator()); in Act() 460 BB->getTerminator()); in Act() 476 "I", BB->getTerminator()); in Act() 504 new BitCastInst(V, DestTy, "PC", BB->getTerminator())); in Act() 513 new BitCastInst(V, DestTy, "BC", BB->getTerminator())); in Act() 521 new TruncInst(V, DestTy, "Tr", BB->getTerminator())); in Act() 526 new ZExtInst(V, DestTy, "ZE", BB->getTerminator())); in Act() [all …]
|
/external/llvm-project/llvm/tools/llvm-stress/ |
D | llvm-stress.cpp | 347 BB->getTerminator()); in Act() 368 new StoreInst(Val, Ptr, BB->getTerminator()); in Act() 390 Instruction* Term = BB->getTerminator(); in Act() 491 "E", BB->getTerminator()); in Act() 519 BB->getTerminator()); in Act() 538 "I", BB->getTerminator()); in Act() 566 new BitCastInst(V, DestTy, "PC", BB->getTerminator())); in Act() 575 new BitCastInst(V, DestTy, "BC", BB->getTerminator())); in Act() 582 new TruncInst(V, DestTy, "Tr", BB->getTerminator())); in Act() 587 new ZExtInst(V, DestTy, "ZE", BB->getTerminator())); in Act() [all …]
|
/external/llvm-project/llvm/examples/IRTransforms/ |
D | SimplifyCFG.cpp | 145 BranchInst *BI = dyn_cast<BranchInst>(BB.getTerminator()); in eliminateCondBranches_v1() 181 BranchInst *BI = dyn_cast<BranchInst>(BB.getTerminator()); in eliminateCondBranches_v2() 231 if (!match(BB.getTerminator(), in eliminateCondBranches_v3() 247 BranchInst *NewBranch = BranchInst::Create(TakenSucc, BB.getTerminator()); in eliminateCondBranches_v3() 248 BB.getTerminator()->eraseFromParent(); in eliminateCondBranches_v3() 290 I.moveBefore(Pred->getTerminator()); in mergeIntoSinglePredecessor_v1() 294 Pred->getTerminator()->eraseFromParent(); in mergeIntoSinglePredecessor_v1() 341 I.moveBefore(Pred->getTerminator()); in mergeIntoSinglePredecessor_v2() 345 Pred->getTerminator()->eraseFromParent(); in mergeIntoSinglePredecessor_v2()
|
/external/llvm-project/llvm/lib/Transforms/Scalar/ |
D | JumpThreading.cpp | 220 BranchInst *CondBr = dyn_cast<BranchInst>(BB->getTerminator()); in updatePredecessorProfileMetadata() 243 BranchInst *PredBr = dyn_cast<BranchInst>(PredBB->getTerminator()); in updatePredecessorProfileMetadata() 279 BranchInst *PredBr = dyn_cast<BranchInst>(PredBB->getTerminator()); in updatePredecessorProfileMetadata() 439 << "' with terminator: " << *BB.getTerminator() in runImpl() 450 auto *BI = dyn_cast<BranchInst>(BB.getTerminator()); in runImpl() 518 if (BB->getTerminator() == StopAt) { in getJumpThreadDuplicationCost() 988 Instruction *BBTerm = BB->getTerminator(); in getBestDestForJumpOnUndef() 1044 Instruction *Terminator = BB->getTerminator(); in processBlock() 1086 Instruction *BBTerm = BB->getTerminator(); in processBlock() 1110 << "' folding terminator: " << *BB->getTerminator() in processBlock() [all …]
|
/external/swiftshader/third_party/llvm-10.0/llvm/lib/Transforms/Scalar/ |
D | JumpThreading.cpp | 212 BranchInst *CondBr = dyn_cast<BranchInst>(BB->getTerminator()); in updatePredecessorProfileMetadata() 230 BranchInst *PredBr = dyn_cast<BranchInst>(PredBB->getTerminator()); in updatePredecessorProfileMetadata() 265 BranchInst *PredBr = dyn_cast<BranchInst>(PredBB->getTerminator()); in updatePredecessorProfileMetadata() 409 << "' with terminator: " << *BB.getTerminator() in runImpl() 420 auto *BI = dyn_cast<BranchInst>(BB.getTerminator()); in runImpl() 487 if (BB->getTerminator() == StopAt) { in getJumpThreadDuplicationCost() 965 Instruction *BBTerm = BB->getTerminator(); in GetBestDestForJumpOnUndef() 1021 Instruction *Terminator = BB->getTerminator(); in ProcessBlock() 1057 Instruction *BBTerm = BB->getTerminator(); in ProcessBlock() 1079 << "' folding terminator: " << *BB->getTerminator() in ProcessBlock() [all …]
|
/external/llvm-project/polly/lib/CodeGen/ |
D | CodeGeneration.cpp | 79 auto *OrigTerminator = Block.getTerminator(); in markBlockUnreachable() 212 Builder.SetInsertPoint(EnteringBB->getTerminator()); in CodeGen() 238 P.insertRegionStart(SplitBlock->getTerminator()); in CodeGen() 241 P.insertRegionEnd(MergeBlock->getTerminator()); in CodeGen() 249 Builder.SetInsertPoint(SplitBlock->getTerminator()); in CodeGen() 254 auto *SplitBBTerm = Builder.GetInsertBlock()->getTerminator(); in CodeGen() 275 Builder.GetInsertBlock()->getTerminator()->setOperand(0, RTC); in CodeGen() 283 Builder.SetInsertPoint(StartBlock->getTerminator()); in CodeGen()
|
/external/tensorflow/tensorflow/compiler/mlir/tensorflow/transforms/ |
D | resource_op_lifting_cleanup.cc | 159 func.front().getTerminator()->eraseOperand(result_idx); in EliminateUnusedResultsForIfCase() 189 func.front().getTerminator()->getOperandTypes())); in EliminateUnusedResultsForIfCase() 206 Operation *body_ret = body.front().getTerminator(); in EliminateUnusedResultsForWhile() 229 cloned_body.front().getTerminator()->eraseOperand(idx); in EliminateUnusedResultsForWhile() 237 func.front().getTerminator()->getOperandTypes())); in EliminateUnusedResultsForWhile() 260 auto ret = func.front().getTerminator(); in ForwardCommonArgToOutput() 342 op->getRegion(0).front().getTerminator()->getOperand(result_idx); in CanonicalizeRegionIfCaseCluster() 344 Value ret = region.front().getTerminator()->getOperand(result_idx); in CanonicalizeRegionIfCaseCluster() 362 region.front().getTerminator()->eraseOperand(result_idx); in CanonicalizeRegionIfCaseCluster() 381 .getTerminator() in CanonicalizeWhileRegion() [all …]
|
D | merge_control_flow.cc | 228 destination.then_branch().front().getTerminator()->getOperand( in CreateMergedIf() 233 destination.else_branch().front().getTerminator()->getOperand( in CreateMergedIf() 256 destination.then_branch().front().getTerminator()->getOperand(i)); in CreateMergedIf() 259 source.then_branch().front().getTerminator()->getOperand(i)); in CreateMergedIf() 262 destination.then_branch().front().getTerminator()->getLoc(), in CreateMergedIf() 268 destination.else_branch().front().getTerminator()->getOperand(i)); in CreateMergedIf() 271 source.else_branch().front().getTerminator()->getOperand(i)); in CreateMergedIf() 274 destination.else_branch().front().getTerminator()->getLoc(), in CreateMergedIf()
|
/external/llvm/lib/Transforms/Scalar/ |
D | JumpThreading.cpp | 209 << "' with terminator: " << *BB->getTerminator() << '\n'); in runImpl() 217 BranchInst *BI = dyn_cast<BranchInst>(BB->getTerminator()); in runImpl() 269 const TerminatorInst *BBTerm = BB->getTerminator(); in getJumpThreadDuplicationCost() 674 TerminatorInst *BBTerm = BB->getTerminator(); in GetBestDestForJumpOnUndef() 715 const TerminatorInst *TI = SinglePred->getTerminator(); in ProcessBlock() 738 Instruction *Terminator = BB->getTerminator(); in ProcessBlock() 772 TerminatorInst *BBTerm = BB->getTerminator(); in ProcessBlock() 790 << "' folding terminator: " << *BB->getTerminator() << '\n'); in ProcessBlock() 812 BranchInst *CondBr = dyn_cast<BranchInst>(BB->getTerminator()); in ProcessBlock() 870 if (PN->getParent() == BB && isa<BranchInst>(BB->getTerminator())) in ProcessBlock() [all …]
|
/external/llvm-project/mlir/lib/Conversion/SCFToStandard/ |
D | SCFToStandard.cpp | 307 Operation *terminator = lastBodyBlock->getTerminator(); in matchAndRewrite() 371 Operation *thenTerminator = thenRegion.back().getTerminator(); in matchAndRewrite() 385 Operation *elseTerminator = elseRegion.back().getTerminator(); in matchAndRewrite() 453 yieldOperands.push_back(reduceBlock.getTerminator()->getOperand(0)); in matchAndRewrite() 454 rewriter.eraseOp(reduceBlock.getTerminator()); in matchAndRewrite() 460 rewriter.eraseOp(parallelOp.getBody()->getTerminator()); in matchAndRewrite() 465 rewriter.mergeBlockBefore(parallelOp.getBody(), newBody->getTerminator(), in matchAndRewrite() 506 auto condOp = cast<ConditionOp>(beforeLast->getTerminator()); in matchAndRewrite() 512 auto yieldOp = cast<scf::YieldOp>(afterLast->getTerminator()); in matchAndRewrite() 559 auto condOp = cast<ConditionOp>(beforeLast->getTerminator()); in matchAndRewrite()
|
/external/llvm-project/llvm/lib/CodeGen/ |
D | HardwareLoops.cpp | 350 if (!isa<BranchInst>(Pred->getTerminator())) in CanGenerateTest() 353 auto *BI = cast<BranchInst>(Pred->getTerminator()); in CanGenerateTest() 400 cast<BranchInst>(BB->getTerminator())->isUnconditional()) { in InitLoopCount() 404 if (!isSafeToExpandAt(TripCount, Predecessor->getTerminator(), SE)) in InitLoopCount() 410 if (!isSafeToExpandAt(TripCount, BB->getTerminator(), SE)) { in InitLoopCount() 417 BB->getTerminator()); in InitLoopCount() 436 IRBuilder<> Builder(BeginBB->getTerminator()); in InsertIterationSetup() 447 assert((isa<BranchInst>(BeginBB->getTerminator()) && in InsertIterationSetup() 448 cast<BranchInst>(BeginBB->getTerminator())->isConditional()) && in InsertIterationSetup() 450 auto *LoopGuard = cast<BranchInst>(BeginBB->getTerminator()); in InsertIterationSetup()
|