Home | History | Annotate | Download | only in Utils

Lines Matching refs:Loop

1 //===-- LCSSA.cpp - Convert loops into loop-closed SSA form ---------------===//
11 // all values that are live across the loop boundary. For example, it turns
25 // transformation is that it makes many other loop optimizations, such as
50 STATISTIC(NumLCSSA, "Number of live out of a loop variables");
61 /// Given an instruction in the loop, check to see if it has any uses that are
62 /// outside the current loop. If so, insert LCSSA PHI nodes and rewrite the
64 static bool processInstruction(Loop &L, Instruction &Inst, DominatorTree &DT,
70 // We can run into tokens which are live out of a loop with catchswitch
72 // is inside the loop and another which is not.
88 // If there are no uses outside the loop, exit with no change.
123 // Add inputs from inside the loop for this PHI.
127 // If the exit block has a predecessor not within the loop, arrange for
143 // for Loop L1 is the header of a disjoint Loop L2. Thus, when we create
154 // Rewrite all uses outside the loop in terms of the new PHIs we just
178 // Post process PHI instructions that were inserted into another disjoint loop
185 Loop *OtherLoop = LI->getLoopFor(PHIBB);
219 bool llvm::formLCSSA(Loop &L, DominatorTree &DT, LoopInfo *LI,
232 // Look at all the instructions in the loop, checking to see if they have uses
233 // outside the loop. If so, rewrite those uses.
236 // particular, if a block does not dominate any of the loop exits, then none
237 // of the values defined in the block could be used outside the loop.
253 // If we modified the code, remove any caches about the loop from SCEV to
264 /// Process a loop nest depth first.
265 bool llvm::formLCSSARecursively(Loop &L, DominatorTree &DT, LoopInfo *LI,
270 for (Loop *SubLoop : L.getSubLoops())
291 /// This transformation requires natural loop information & requires that
292 /// loop preheaders be inserted into the CFG. It maintains both of these,
309 INITIALIZE_PASS_BEGIN(LCSSA, "lcssa", "Loop-Closed SSA Form Pass", false, false)
314 INITIALIZE_PASS_END(LCSSA, "lcssa", "Loop-Closed SSA Form Pass", false, false)
328 // Simplify each loop nest in the function.