| /src/external/apache2/llvm/dist/llvm/lib/Transforms/Utils/ |
| LoopPeel.cpp | 99 // Latch's terminator is a conditional branch, Latch is exiting and 100 // all non Latch exits ends up with deoptimize. 101 const BasicBlock *Latch = L->getLoopLatch(); 102 const BranchInst *T = dyn_cast<BranchInst>(Latch->getTerminator()); 103 return T && T->isConditional() && L->isLoopExiting(Latch) && 114 // Don't try to peel loops where the latch is not the exiting block. 117 // 2) The loop contains irreducible control flow that involves the latch. 118 const BasicBlock *Latch = L->getLoopLatch(); 119 if (Latch != L->getExitingBlock() [all...] |
| MatrixUtils.cpp | 32 BasicBlock *Latch = BasicBlock::Create(Header->getContext(), Name + ".latch", 37 BranchInst::Create(Latch, Body); 42 B.SetInsertPoint(Latch); 45 BranchInst::Create(Header, Exit, Cond, Latch); 46 IV->addIncoming(Inc, Latch); 54 {DominatorTree::Insert, Body, Latch}, 55 {DominatorTree::Insert, Latch, Header}, 56 {DominatorTree::Insert, Latch, Exit}, 62 L->addBasicBlockToLoop(Latch, LI) [all...] |
| LoopRotationUtils.cpp | 58 "a better latch exit")); 191 // Assuming both header and latch are exiting, look for a phi which is only 213 // Check that latch exit is deoptimizing (which means - very unlikely to happen) 215 // If we rotate latch to that exit our loop has a better chance of being fully 220 BasicBlock *Latch = L->getLoopLatch(); 221 assert(Latch && "need latch"); 222 BranchInst *BI = dyn_cast<BranchInst>(Latch->getTerminator()); 223 // Need normal exiting latch. 231 // Latch exit is non-deoptimizing, no need to rotate [all...] |
| LoopUnrollAndJam.cpp | 133 // Looks at the phi nodes in Header for values coming from Latch. For these 142 static bool processHeaderPhiOperands(BasicBlock *Header, BasicBlock *Latch, 147 Value *V = Phi.getIncomingValueForBlock(Latch); 168 // Move the phi operands of Header from Latch out of AftBlocks to InsertLoc. 170 BasicBlock *Latch, 176 processHeaderPhiOperands(Header, Latch, AftBlocks, 305 assert(LatchBlock && "No latch block"); 974 BasicBlock *Latch = L->getLoopLatch(); 978 Header, Latch, AftBlocks, [&AftBlocks, &SubLoop](Instruction *I) {
|
| LoopUnrollRuntime.cpp | 55 cl::desc("Assume the non latch exit block to be predictable")); 85 // Latch 87 BasicBlock *Latch = L->getLoopLatch(); 88 assert(Latch && "Loop must have a latch"); 89 BasicBlock *PrologLatch = cast<BasicBlock>(VMap[Latch]); 96 for (BasicBlock *Succ : successors(Latch)) { 118 Value *V = PN.getIncomingValueForBlock(Latch); 191 BasicBlock *Latch = L->getLoopLatch(); 192 assert(Latch && "Loop must have a latch") [all...] |
| LoopUtils.cpp | 767 auto *Latch = L->getLoopLatch(); 768 assert(Latch && "multiple latches not yet supported"); 784 auto *BackedgeBB = SplitEdge(Latch, Header, &DT, &LI, MSSAU.get()); 804 /// Checks if \p L has single exit through latch block except possibly 806 /// latch if above check is successful, nullptr otherwise. 808 BasicBlock *Latch = L->getLoopLatch(); 809 if (!Latch) 812 BranchInst *LatchBR = dyn_cast<BranchInst>(Latch->getTerminator()); 813 if (!LatchBR || LatchBR->getNumSuccessors() != 2 || !L->isLoopExiting(Latch)) 818 "At least one edge out of the latch must go to the header") [all...] |
| /src/external/apache2/llvm/dist/llvm/include/llvm/Support/ |
| Parallel.h | 36 class Latch { 42 explicit Latch(uint32_t Count = 0) : Count(Count) {} 43 ~Latch() { sync(); } 63 Latch L;
|
| /src/external/apache2/llvm/dist/llvm/lib/Analysis/ |
| LoopNestAnalysis.cpp | 31 /// or jump around the inner loop to the outer loop latch 32 /// - if the inner loop latch exits the inner loop, it should 'flow' into 33 /// the outer loop latch. 64 // or jump around the inner loop to the outer loop latch 65 // - if the inner loop latch exits the inner loop, it should 'flow' into 66 // the outer loop latch. 80 // Identify the outer loop latch comparison instruction. 81 const BasicBlock *Latch = OuterLoop.getLoopLatch(); 82 assert(Latch && "Expecting a valid loop latch"); [all...] |
| IVDescriptors.cpp | 725 // Ensure the loop has a preheader and a single latch block. The loop 726 // vectorizer will need the latch to set up the next iteration of the loop. 728 auto *Latch = TheLoop->getLoopLatch(); 729 if (!Preheader || !Latch) 732 // Ensure the phi node's incoming blocks are the loop preheader and latch. 734 Phi->getBasicBlockIndex(Latch) < 0) 737 // Get the previous value. The previous value comes from the latch edge while 739 auto *Previous = dyn_cast<Instruction>(Phi->getIncomingValueForBlock(Latch)); 1101 BasicBlock *Latch = L->getLoopLatch(); 1102 if (!Latch) [all...] |
| LoopAccessAnalysis.cpp | 2097 // Blocks that do not dominate the latch need predication. 2098 BasicBlock* Latch = TheLoop->getLoopLatch(); 2099 return !DT->dominates(BB, Latch);
|
| /src/external/apache2/llvm/dist/llvm/include/llvm/Analysis/ |
| LoopInfoImpl.h | 131 const BlockT *Latch = getLoopLatch(); 132 assert(Latch && "Latch block must exists"); 134 [Latch](const BlockT *BB) { return BB != Latch; }); 213 /// getLoopLatch - If there is a single latch block for this loop, return it. 214 /// A latch block is a block that contains a branch back to the header. 219 BlockT *Latch = nullptr; 222 if (Latch) 224 Latch = Pred [all...] |
| LoopInfo.h | 235 /// Returns true if \p BB is a loop-latch. 236 /// A latch block is a block that contains a branch back to the header. 296 /// Latch block are not considered. If the exit comes from Latch has also 297 /// non Latch predecessor in a loop it will be added to ExitBlocks. 328 /// If there is a single latch block for this loop, return it. 329 /// A latch block is a block that contains a branch back to the header. 332 /// Return all loop latch blocks of this loop. A latch block is a block that 611 /// i_1 = phi[{lb, preheader}, {i_2, latch}] [all...] |
| /src/external/apache2/llvm/dist/llvm/include/llvm/Frontend/OpenMP/ |
| OMPIRBuilder.h | 121 /// latch. 1088 /// \--Latch | 1094 /// Code in the header, condition block, latch and exit block must not have any 1097 /// eventually branch to the latch block. 1112 BasicBlock *Latch; 1139 /// eventually branch to the \p Latch block. 1142 /// Reaching the latch indicates the end of the loop body code. In the 1145 BasicBlock *getLatch() const { return Latch; }
|
| /src/external/apache2/llvm/dist/llvm/lib/CodeGen/ |
| HardwareLoops.cpp | 503 BasicBlock *Latch = ExitBranch->getParent(); 507 Index->addIncoming(EltsRem, Latch);
|
| /src/external/apache2/llvm/dist/llvm/lib/Transforms/Scalar/ |
| LoopFlatten.cpp | 108 // latch. 109 BasicBlock *Latch = L->getLoopLatch(); 110 if (L->getExitingBlock() != Latch) { 111 LLVM_DEBUG(dbgs() << "Exiting and latch block are different\n"); 114 // Latch block must end in a conditional branch. 115 BackBranch = dyn_cast<BranchInst>(Latch->getTerminator()); 180 if (InductionPHI->getIncomingValueForBlock(Latch) != Increment) { 182 dbgs() << "Incoming value from latch is not the increment inst\n"); 224 // from the pre-header, and one from the latch. 255 dbgs() << "LCSSA PHI incoming value does not match latch value\n") [all...] |
| LoopUnrollAndJamPass.cpp | 369 BasicBlock *Latch = L->getLoopLatch(); 371 unsigned OuterTripCount = SE.getSmallConstantTripCount(L, Latch); 372 unsigned OuterTripMultiple = SE.getSmallConstantTripMultiple(L, Latch);
|
| LoopFuse.cpp | 81 STATISTIC(InvalidLatch, "Loop has invalid latch"); 158 /// Latch of the loop 159 BasicBlock *Latch; 191 Latch(L->getLoopLatch()), L(L), Valid(true), 236 return Preheader && Header && ExitingBlock && ExitBlock && Latch && L && 249 assert(Latch == L->getLoopLatch() && "Latch is out of sync"); 271 Latch = L->getLoopLatch(); 309 << "\tLatch: " << (Latch ? Latch->getName() : "nullptr") << "\n [all...] |
| GVN.cpp | 1508 // TODO: Generalize to other loop blocks that dominate the latch. 1513 BasicBlock *Latch = L->getLoopLatch(); 1514 if (!Preheader || !Latch) 1546 // Blocks that dominate the latch execute on every single iteration, maybe 1551 if (DT->dominates(Blocker, Latch))
|
| InductiveRangeCheckElimination.cpp | 119 static cl::opt<bool> AllowUnsignedLatchCondition("irce-allow-unsigned-latch", 123 "irce-allow-narrow-latch", cl::Hidden, cl::init(true), 125 "with narrow latch condition.")); 459 // kinds of loops we can deal with -- ones that have a single latch that is also 465 BasicBlock *Latch = nullptr; 467 // `Latch's terminator instruction is `LatchBr', and it's `LatchBrExitIdx'th 495 Result.Latch = cast<BasicBlock>(Map(Latch)); 760 BasicBlock *Latch = L.getLoopLatch(); 761 assert(Latch && "Simplified loops only have one latch!") [all...] |
| LoopUnswitch.cpp | 1091 /// from its header block to its latch block, where the path through the loop 1270 // latch block or exit through a one exit block without having any 1641 BasicBlock *Latch = L->getLoopLatch(); 1644 // If the DeadCase successor dominates the loop latch, then the 1646 // to the latch. 1647 if (Latch && DT->dominates(SISucc, Latch))
|
| SimpleLoopUnswitch.cpp | 2537 // explosion as soon as they dominate the latch (otherwise there might be 2538 // another path to the latch remaining that does not allow to eliminate the 2540 BasicBlock *Latch = L.getLoopLatch(); 2542 if (DT.dominates(CondBlock, Latch) && 2560 bool SkipExitingSuccessors = DT.dominates(CondBlock, Latch);
|
| /src/external/apache2/llvm/dist/llvm/lib/Target/ARM/ |
| MVETPAndVPTOptimisationsPass.cpp | 110 MachineBasicBlock *Latch = ML->getLoopLatch(); 111 if (!Header || !Latch) { 112 LLVM_DEBUG(dbgs() << " no Loop Latch or Header\n"); 118 for (auto &T : Latch->terminators()) { 160 (LoopPhi->getOperand(2).getMBB() != Latch && 161 LoopPhi->getOperand(4).getMBB() != Latch)) { 167 Register StartReg = LoopPhi->getOperand(2).getMBB() == Latch
|
| /src/external/apache2/llvm/dist/llvm/lib/Transforms/Vectorize/ |
| LoopVectorizationLegality.cpp | 279 // 2) its latch terminator is a conditional branch and, 280 // 3) its latch condition is a compare instruction whose operands are the 283 // related to the loop latch because they don't affect the loop uniformity. 297 assert(Lp->getLoopLatch() && "Expected loop with a single latch."); 312 BasicBlock *Latch = Lp->getLoopLatch(); 313 auto *LatchBr = dyn_cast<BranchInst>(Latch->getTerminator()); 315 LLVM_DEBUG(dbgs() << "LV: Unsupported loop latch branch.\n"); 323 dbgs() << "LV: Loop latch condition is not a compare instruction.\n"); 329 Value *IVUpdate = IV->getIncomingValueForBlock(Latch); 332 LLVM_DEBUG(dbgs() << "LV: Loop latch condition is not uniform.\n") [all...] |
| /src/external/apache2/llvm/dist/llvm/lib/Target/X86/ |
| X86LowerAMXIntrinsics.cpp | 112 BasicBlock *Latch = 113 BasicBlock::Create(Ctx, Name + ".latch", Header->getParent(), Exit); 117 BranchInst::Create(Latch, Body); 122 B.SetInsertPoint(Latch); 125 BranchInst::Create(Header, Exit, Cond, Latch); 126 IV->addIncoming(Inc, Latch); 134 {DominatorTree::Insert, Body, Latch}, 135 {DominatorTree::Insert, Latch, Header}, 136 {DominatorTree::Insert, Latch, Exit}, 142 L->addBasicBlockToLoop(Latch, *LI) [all...] |
| /src/external/apache2/llvm/dist/llvm/lib/Target/Hexagon/ |
| HexagonHardwareLoops.cpp | 280 /// The desired flow is: phi ---> bump -+-> comparison-in-latch. 289 /// +-> comparison-in-latch (against upper_bound-bump), 296 /// couldn't be identified, or if the value in the latch's comparison 409 MachineBasicBlock *Latch = L->getLoopLatch(); 411 if (!Header || !Preheader || !Latch || !ExitingBlock) 433 // latch block, and see if is a result of an addition of form "reg+imm", 436 if (Phi->getOperand(i+1).getMBB() != Latch) 606 MachineBasicBlock *Latch = L->getLoopLatch(); 611 else if (MBB == Latch) 628 if (ExitingBlock != Latch && (TB == Latch || FB == Latch)) [all...] |