858cc642f41a66bf8f6f2d62443184fea186b9c1
[oota-llvm.git] / lib / Analysis / LoopInfo.cpp
1 //===- LoopInfo.cpp - Natural Loop Calculator -----------------------------===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file defines the LoopInfo class that is used to identify natural loops
11 // and determine the loop depth of various nodes of the CFG.  Note that the
12 // loops identified may actually be several natural loops that share the same
13 // header node... not just a single natural loop.
14 //
15 //===----------------------------------------------------------------------===//
16
17 #include "llvm/Analysis/LoopInfo.h"
18 #include "llvm/Constants.h"
19 #include "llvm/Instructions.h"
20 #include "llvm/Analysis/Dominators.h"
21 #include "llvm/Analysis/LoopIterator.h"
22 #include "llvm/Analysis/ValueTracking.h"
23 #include "llvm/Assembly/Writer.h"
24 #include "llvm/Support/CFG.h"
25 #include "llvm/Support/CommandLine.h"
26 #include "llvm/Support/Debug.h"
27 #include "llvm/ADT/DepthFirstIterator.h"
28 #include "llvm/ADT/SmallPtrSet.h"
29 #include <algorithm>
30 using namespace llvm;
31
32 // Always verify loopinfo if expensive checking is enabled.
33 #ifdef XDEBUG
34 static bool VerifyLoopInfo = true;
35 #else
36 static bool VerifyLoopInfo = false;
37 #endif
38 static cl::opt<bool,true>
39 VerifyLoopInfoX("verify-loop-info", cl::location(VerifyLoopInfo),
40                 cl::desc("Verify loop info (time consuming)"));
41
42 char LoopInfo::ID = 0;
43 INITIALIZE_PASS_BEGIN(LoopInfo, "loops", "Natural Loop Information", true, true)
44 INITIALIZE_PASS_DEPENDENCY(DominatorTree)
45 INITIALIZE_PASS_END(LoopInfo, "loops", "Natural Loop Information", true, true)
46
47 //===----------------------------------------------------------------------===//
48 // Loop implementation
49 //
50
51 /// isLoopInvariant - Return true if the specified value is loop invariant
52 ///
53 bool Loop::isLoopInvariant(Value *V) const {
54   if (Instruction *I = dyn_cast<Instruction>(V))
55     return !contains(I);
56   return true;  // All non-instructions are loop invariant
57 }
58
59 /// hasLoopInvariantOperands - Return true if all the operands of the
60 /// specified instruction are loop invariant.
61 bool Loop::hasLoopInvariantOperands(Instruction *I) const {
62   for (unsigned i = 0, e = I->getNumOperands(); i != e; ++i)
63     if (!isLoopInvariant(I->getOperand(i)))
64       return false;
65
66   return true;
67 }
68
69 /// makeLoopInvariant - If the given value is an instruciton inside of the
70 /// loop and it can be hoisted, do so to make it trivially loop-invariant.
71 /// Return true if the value after any hoisting is loop invariant. This
72 /// function can be used as a slightly more aggressive replacement for
73 /// isLoopInvariant.
74 ///
75 /// If InsertPt is specified, it is the point to hoist instructions to.
76 /// If null, the terminator of the loop preheader is used.
77 ///
78 bool Loop::makeLoopInvariant(Value *V, bool &Changed,
79                              Instruction *InsertPt) const {
80   if (Instruction *I = dyn_cast<Instruction>(V))
81     return makeLoopInvariant(I, Changed, InsertPt);
82   return true;  // All non-instructions are loop-invariant.
83 }
84
85 /// makeLoopInvariant - If the given instruction is inside of the
86 /// loop and it can be hoisted, do so to make it trivially loop-invariant.
87 /// Return true if the instruction after any hoisting is loop invariant. This
88 /// function can be used as a slightly more aggressive replacement for
89 /// isLoopInvariant.
90 ///
91 /// If InsertPt is specified, it is the point to hoist instructions to.
92 /// If null, the terminator of the loop preheader is used.
93 ///
94 bool Loop::makeLoopInvariant(Instruction *I, bool &Changed,
95                              Instruction *InsertPt) const {
96   // Test if the value is already loop-invariant.
97   if (isLoopInvariant(I))
98     return true;
99   if (!isSafeToSpeculativelyExecute(I))
100     return false;
101   if (I->mayReadFromMemory())
102     return false;
103   // The landingpad instruction is immobile.
104   if (isa<LandingPadInst>(I))
105     return false;
106   // Determine the insertion point, unless one was given.
107   if (!InsertPt) {
108     BasicBlock *Preheader = getLoopPreheader();
109     // Without a preheader, hoisting is not feasible.
110     if (!Preheader)
111       return false;
112     InsertPt = Preheader->getTerminator();
113   }
114   // Don't hoist instructions with loop-variant operands.
115   for (unsigned i = 0, e = I->getNumOperands(); i != e; ++i)
116     if (!makeLoopInvariant(I->getOperand(i), Changed, InsertPt))
117       return false;
118
119   // Hoist.
120   I->moveBefore(InsertPt);
121   Changed = true;
122   return true;
123 }
124
125 /// getCanonicalInductionVariable - Check to see if the loop has a canonical
126 /// induction variable: an integer recurrence that starts at 0 and increments
127 /// by one each time through the loop.  If so, return the phi node that
128 /// corresponds to it.
129 ///
130 /// The IndVarSimplify pass transforms loops to have a canonical induction
131 /// variable.
132 ///
133 PHINode *Loop::getCanonicalInductionVariable() const {
134   BasicBlock *H = getHeader();
135
136   BasicBlock *Incoming = 0, *Backedge = 0;
137   pred_iterator PI = pred_begin(H);
138   assert(PI != pred_end(H) &&
139          "Loop must have at least one backedge!");
140   Backedge = *PI++;
141   if (PI == pred_end(H)) return 0;  // dead loop
142   Incoming = *PI++;
143   if (PI != pred_end(H)) return 0;  // multiple backedges?
144
145   if (contains(Incoming)) {
146     if (contains(Backedge))
147       return 0;
148     std::swap(Incoming, Backedge);
149   } else if (!contains(Backedge))
150     return 0;
151
152   // Loop over all of the PHI nodes, looking for a canonical indvar.
153   for (BasicBlock::iterator I = H->begin(); isa<PHINode>(I); ++I) {
154     PHINode *PN = cast<PHINode>(I);
155     if (ConstantInt *CI =
156         dyn_cast<ConstantInt>(PN->getIncomingValueForBlock(Incoming)))
157       if (CI->isNullValue())
158         if (Instruction *Inc =
159             dyn_cast<Instruction>(PN->getIncomingValueForBlock(Backedge)))
160           if (Inc->getOpcode() == Instruction::Add &&
161                 Inc->getOperand(0) == PN)
162             if (ConstantInt *CI = dyn_cast<ConstantInt>(Inc->getOperand(1)))
163               if (CI->equalsInt(1))
164                 return PN;
165   }
166   return 0;
167 }
168
169 /// isLCSSAForm - Return true if the Loop is in LCSSA form
170 bool Loop::isLCSSAForm(DominatorTree &DT) const {
171   // Sort the blocks vector so that we can use binary search to do quick
172   // lookups.
173   SmallPtrSet<BasicBlock*, 16> LoopBBs(block_begin(), block_end());
174
175   for (block_iterator BI = block_begin(), E = block_end(); BI != E; ++BI) {
176     BasicBlock *BB = *BI;
177     for (BasicBlock::iterator I = BB->begin(), E = BB->end(); I != E;++I)
178       for (Value::use_iterator UI = I->use_begin(), E = I->use_end(); UI != E;
179            ++UI) {
180         User *U = *UI;
181         BasicBlock *UserBB = cast<Instruction>(U)->getParent();
182         if (PHINode *P = dyn_cast<PHINode>(U))
183           UserBB = P->getIncomingBlock(UI);
184
185         // Check the current block, as a fast-path, before checking whether
186         // the use is anywhere in the loop.  Most values are used in the same
187         // block they are defined in.  Also, blocks not reachable from the
188         // entry are special; uses in them don't need to go through PHIs.
189         if (UserBB != BB &&
190             !LoopBBs.count(UserBB) &&
191             DT.isReachableFromEntry(UserBB))
192           return false;
193       }
194   }
195
196   return true;
197 }
198
199 /// isLoopSimplifyForm - Return true if the Loop is in the form that
200 /// the LoopSimplify form transforms loops to, which is sometimes called
201 /// normal form.
202 bool Loop::isLoopSimplifyForm() const {
203   // Normal-form loops have a preheader, a single backedge, and all of their
204   // exits have all their predecessors inside the loop.
205   return getLoopPreheader() && getLoopLatch() && hasDedicatedExits();
206 }
207
208 /// hasDedicatedExits - Return true if no exit block for the loop
209 /// has a predecessor that is outside the loop.
210 bool Loop::hasDedicatedExits() const {
211   // Sort the blocks vector so that we can use binary search to do quick
212   // lookups.
213   SmallPtrSet<BasicBlock *, 16> LoopBBs(block_begin(), block_end());
214   // Each predecessor of each exit block of a normal loop is contained
215   // within the loop.
216   SmallVector<BasicBlock *, 4> ExitBlocks;
217   getExitBlocks(ExitBlocks);
218   for (unsigned i = 0, e = ExitBlocks.size(); i != e; ++i)
219     for (pred_iterator PI = pred_begin(ExitBlocks[i]),
220          PE = pred_end(ExitBlocks[i]); PI != PE; ++PI)
221       if (!LoopBBs.count(*PI))
222         return false;
223   // All the requirements are met.
224   return true;
225 }
226
227 /// getUniqueExitBlocks - Return all unique successor blocks of this loop.
228 /// These are the blocks _outside of the current loop_ which are branched to.
229 /// This assumes that loop exits are in canonical form.
230 ///
231 void
232 Loop::getUniqueExitBlocks(SmallVectorImpl<BasicBlock *> &ExitBlocks) const {
233   assert(hasDedicatedExits() &&
234          "getUniqueExitBlocks assumes the loop has canonical form exits!");
235
236   // Sort the blocks vector so that we can use binary search to do quick
237   // lookups.
238   SmallVector<BasicBlock *, 128> LoopBBs(block_begin(), block_end());
239   std::sort(LoopBBs.begin(), LoopBBs.end());
240
241   SmallVector<BasicBlock *, 32> switchExitBlocks;
242
243   for (block_iterator BI = block_begin(), BE = block_end(); BI != BE; ++BI) {
244
245     BasicBlock *current = *BI;
246     switchExitBlocks.clear();
247
248     for (succ_iterator I = succ_begin(*BI), E = succ_end(*BI); I != E; ++I) {
249       // If block is inside the loop then it is not a exit block.
250       if (std::binary_search(LoopBBs.begin(), LoopBBs.end(), *I))
251         continue;
252
253       pred_iterator PI = pred_begin(*I);
254       BasicBlock *firstPred = *PI;
255
256       // If current basic block is this exit block's first predecessor
257       // then only insert exit block in to the output ExitBlocks vector.
258       // This ensures that same exit block is not inserted twice into
259       // ExitBlocks vector.
260       if (current != firstPred)
261         continue;
262
263       // If a terminator has more then two successors, for example SwitchInst,
264       // then it is possible that there are multiple edges from current block
265       // to one exit block.
266       if (std::distance(succ_begin(current), succ_end(current)) <= 2) {
267         ExitBlocks.push_back(*I);
268         continue;
269       }
270
271       // In case of multiple edges from current block to exit block, collect
272       // only one edge in ExitBlocks. Use switchExitBlocks to keep track of
273       // duplicate edges.
274       if (std::find(switchExitBlocks.begin(), switchExitBlocks.end(), *I)
275           == switchExitBlocks.end()) {
276         switchExitBlocks.push_back(*I);
277         ExitBlocks.push_back(*I);
278       }
279     }
280   }
281 }
282
283 /// getUniqueExitBlock - If getUniqueExitBlocks would return exactly one
284 /// block, return that block. Otherwise return null.
285 BasicBlock *Loop::getUniqueExitBlock() const {
286   SmallVector<BasicBlock *, 8> UniqueExitBlocks;
287   getUniqueExitBlocks(UniqueExitBlocks);
288   if (UniqueExitBlocks.size() == 1)
289     return UniqueExitBlocks[0];
290   return 0;
291 }
292
293 void Loop::dump() const {
294   print(dbgs());
295 }
296
297 //===----------------------------------------------------------------------===//
298 // UnloopUpdater implementation
299 //
300
301 namespace {
302 /// Find the new parent loop for all blocks within the "unloop" whose last
303 /// backedges has just been removed.
304 class UnloopUpdater {
305   Loop *Unloop;
306   LoopInfo *LI;
307
308   LoopBlocksDFS DFS;
309
310   // Map unloop's immediate subloops to their nearest reachable parents. Nested
311   // loops within these subloops will not change parents. However, an immediate
312   // subloop's new parent will be the nearest loop reachable from either its own
313   // exits *or* any of its nested loop's exits.
314   DenseMap<Loop*, Loop*> SubloopParents;
315
316   // Flag the presence of an irreducible backedge whose destination is a block
317   // directly contained by the original unloop.
318   bool FoundIB;
319
320 public:
321   UnloopUpdater(Loop *UL, LoopInfo *LInfo) :
322     Unloop(UL), LI(LInfo), DFS(UL), FoundIB(false) {}
323
324   void updateBlockParents();
325
326   void removeBlocksFromAncestors();
327
328   void updateSubloopParents();
329
330 protected:
331   Loop *getNearestLoop(BasicBlock *BB, Loop *BBLoop);
332 };
333 } // end anonymous namespace
334
335 /// updateBlockParents - Update the parent loop for all blocks that are directly
336 /// contained within the original "unloop".
337 void UnloopUpdater::updateBlockParents() {
338   if (Unloop->getNumBlocks()) {
339     // Perform a post order CFG traversal of all blocks within this loop,
340     // propagating the nearest loop from sucessors to predecessors.
341     LoopBlocksTraversal Traversal(DFS, LI);
342     for (LoopBlocksTraversal::POTIterator POI = Traversal.begin(),
343            POE = Traversal.end(); POI != POE; ++POI) {
344
345       Loop *L = LI->getLoopFor(*POI);
346       Loop *NL = getNearestLoop(*POI, L);
347
348       if (NL != L) {
349         // For reducible loops, NL is now an ancestor of Unloop.
350         assert((NL != Unloop && (!NL || NL->contains(Unloop))) &&
351                "uninitialized successor");
352         LI->changeLoopFor(*POI, NL);
353       }
354       else {
355         // Or the current block is part of a subloop, in which case its parent
356         // is unchanged.
357         assert((FoundIB || Unloop->contains(L)) && "uninitialized successor");
358       }
359     }
360   }
361   // Each irreducible loop within the unloop induces a round of iteration using
362   // the DFS result cached by Traversal.
363   bool Changed = FoundIB;
364   for (unsigned NIters = 0; Changed; ++NIters) {
365     assert(NIters < Unloop->getNumBlocks() && "runaway iterative algorithm");
366
367     // Iterate over the postorder list of blocks, propagating the nearest loop
368     // from successors to predecessors as before.
369     Changed = false;
370     for (LoopBlocksDFS::POIterator POI = DFS.beginPostorder(),
371            POE = DFS.endPostorder(); POI != POE; ++POI) {
372
373       Loop *L = LI->getLoopFor(*POI);
374       Loop *NL = getNearestLoop(*POI, L);
375       if (NL != L) {
376         assert(NL != Unloop && (!NL || NL->contains(Unloop)) &&
377                "uninitialized successor");
378         LI->changeLoopFor(*POI, NL);
379         Changed = true;
380       }
381     }
382   }
383 }
384
385 /// removeBlocksFromAncestors - Remove unloop's blocks from all ancestors below
386 /// their new parents.
387 void UnloopUpdater::removeBlocksFromAncestors() {
388   // Remove all unloop's blocks (including those in nested subloops) from
389   // ancestors below the new parent loop.
390   for (Loop::block_iterator BI = Unloop->block_begin(),
391          BE = Unloop->block_end(); BI != BE; ++BI) {
392     Loop *OuterParent = LI->getLoopFor(*BI);
393     if (Unloop->contains(OuterParent)) {
394       while (OuterParent->getParentLoop() != Unloop)
395         OuterParent = OuterParent->getParentLoop();
396       OuterParent = SubloopParents[OuterParent];
397     }
398     // Remove blocks from former Ancestors except Unloop itself which will be
399     // deleted.
400     for (Loop *OldParent = Unloop->getParentLoop(); OldParent != OuterParent;
401          OldParent = OldParent->getParentLoop()) {
402       assert(OldParent && "new loop is not an ancestor of the original");
403       OldParent->removeBlockFromLoop(*BI);
404     }
405   }
406 }
407
408 /// updateSubloopParents - Update the parent loop for all subloops directly
409 /// nested within unloop.
410 void UnloopUpdater::updateSubloopParents() {
411   while (!Unloop->empty()) {
412     Loop *Subloop = *llvm::prior(Unloop->end());
413     Unloop->removeChildLoop(llvm::prior(Unloop->end()));
414
415     assert(SubloopParents.count(Subloop) && "DFS failed to visit subloop");
416     if (SubloopParents[Subloop])
417       SubloopParents[Subloop]->addChildLoop(Subloop);
418     else
419       LI->addTopLevelLoop(Subloop);
420   }
421 }
422
423 /// getNearestLoop - Return the nearest parent loop among this block's
424 /// successors. If a successor is a subloop header, consider its parent to be
425 /// the nearest parent of the subloop's exits.
426 ///
427 /// For subloop blocks, simply update SubloopParents and return NULL.
428 Loop *UnloopUpdater::getNearestLoop(BasicBlock *BB, Loop *BBLoop) {
429
430   // Initially for blocks directly contained by Unloop, NearLoop == Unloop and
431   // is considered uninitialized.
432   Loop *NearLoop = BBLoop;
433
434   Loop *Subloop = 0;
435   if (NearLoop != Unloop && Unloop->contains(NearLoop)) {
436     Subloop = NearLoop;
437     // Find the subloop ancestor that is directly contained within Unloop.
438     while (Subloop->getParentLoop() != Unloop) {
439       Subloop = Subloop->getParentLoop();
440       assert(Subloop && "subloop is not an ancestor of the original loop");
441     }
442     // Get the current nearest parent of the Subloop exits, initially Unloop.
443     if (!SubloopParents.count(Subloop))
444       SubloopParents[Subloop] = Unloop;
445     NearLoop = SubloopParents[Subloop];
446   }
447
448   succ_iterator I = succ_begin(BB), E = succ_end(BB);
449   if (I == E) {
450     assert(!Subloop && "subloop blocks must have a successor");
451     NearLoop = 0; // unloop blocks may now exit the function.
452   }
453   for (; I != E; ++I) {
454     if (*I == BB)
455       continue; // self loops are uninteresting
456
457     Loop *L = LI->getLoopFor(*I);
458     if (L == Unloop) {
459       // This successor has not been processed. This path must lead to an
460       // irreducible backedge.
461       assert((FoundIB || !DFS.hasPostorder(*I)) && "should have seen IB");
462       FoundIB = true;
463     }
464     if (L != Unloop && Unloop->contains(L)) {
465       // Successor is in a subloop.
466       if (Subloop)
467         continue; // Branching within subloops. Ignore it.
468
469       // BB branches from the original into a subloop header.
470       assert(L->getParentLoop() == Unloop && "cannot skip into nested loops");
471
472       // Get the current nearest parent of the Subloop's exits.
473       L = SubloopParents[L];
474       // L could be Unloop if the only exit was an irreducible backedge.
475     }
476     if (L == Unloop) {
477       continue;
478     }
479     // Handle critical edges from Unloop into a sibling loop.
480     if (L && !L->contains(Unloop)) {
481       L = L->getParentLoop();
482     }
483     // Remember the nearest parent loop among successors or subloop exits.
484     if (NearLoop == Unloop || !NearLoop || NearLoop->contains(L))
485       NearLoop = L;
486   }
487   if (Subloop) {
488     SubloopParents[Subloop] = NearLoop;
489     return BBLoop;
490   }
491   return NearLoop;
492 }
493
494 //===----------------------------------------------------------------------===//
495 // LoopInfo implementation
496 //
497 bool LoopInfo::runOnFunction(Function &) {
498   releaseMemory();
499   LI.Calculate(getAnalysis<DominatorTree>().getBase());    // Update
500   return false;
501 }
502
503 /// updateUnloop - The last backedge has been removed from a loop--now the
504 /// "unloop". Find a new parent for the blocks contained within unloop and
505 /// update the loop tree. We don't necessarily have valid dominators at this
506 /// point, but LoopInfo is still valid except for the removal of this loop.
507 ///
508 /// Note that Unloop may now be an empty loop. Calling Loop::getHeader without
509 /// checking first is illegal.
510 void LoopInfo::updateUnloop(Loop *Unloop) {
511
512   // First handle the special case of no parent loop to simplify the algorithm.
513   if (!Unloop->getParentLoop()) {
514     // Since BBLoop had no parent, Unloop blocks are no longer in a loop.
515     for (Loop::block_iterator I = Unloop->block_begin(),
516          E = Unloop->block_end(); I != E; ++I) {
517
518       // Don't reparent blocks in subloops.
519       if (getLoopFor(*I) != Unloop)
520         continue;
521
522       // Blocks no longer have a parent but are still referenced by Unloop until
523       // the Unloop object is deleted.
524       LI.changeLoopFor(*I, 0);
525     }
526
527     // Remove the loop from the top-level LoopInfo object.
528     for (LoopInfo::iterator I = LI.begin();; ++I) {
529       assert(I != LI.end() && "Couldn't find loop");
530       if (*I == Unloop) {
531         LI.removeLoop(I);
532         break;
533       }
534     }
535
536     // Move all of the subloops to the top-level.
537     while (!Unloop->empty())
538       LI.addTopLevelLoop(Unloop->removeChildLoop(llvm::prior(Unloop->end())));
539
540     return;
541   }
542
543   // Update the parent loop for all blocks within the loop. Blocks within
544   // subloops will not change parents.
545   UnloopUpdater Updater(Unloop, this);
546   Updater.updateBlockParents();
547
548   // Remove blocks from former ancestor loops.
549   Updater.removeBlocksFromAncestors();
550
551   // Add direct subloops as children in their new parent loop.
552   Updater.updateSubloopParents();
553
554   // Remove unloop from its parent loop.
555   Loop *ParentLoop = Unloop->getParentLoop();
556   for (Loop::iterator I = ParentLoop->begin();; ++I) {
557     assert(I != ParentLoop->end() && "Couldn't find loop");
558     if (*I == Unloop) {
559       ParentLoop->removeChildLoop(I);
560       break;
561     }
562   }
563 }
564
565 void LoopInfo::verifyAnalysis() const {
566   // LoopInfo is a FunctionPass, but verifying every loop in the function
567   // each time verifyAnalysis is called is very expensive. The
568   // -verify-loop-info option can enable this. In order to perform some
569   // checking by default, LoopPass has been taught to call verifyLoop
570   // manually during loop pass sequences.
571
572   if (!VerifyLoopInfo) return;
573
574   DenseSet<const Loop*> Loops;
575   for (iterator I = begin(), E = end(); I != E; ++I) {
576     assert(!(*I)->getParentLoop() && "Top-level loop has a parent!");
577     (*I)->verifyLoopNest(&Loops);
578   }
579
580   // Verify that blocks are mapped to valid loops.
581   //
582   // FIXME: With an up-to-date DFS (see LoopIterator.h) and DominatorTree, we
583   // could also verify that the blocks are still in the correct loops.
584   for (DenseMap<BasicBlock*, Loop*>::const_iterator I = LI.BBMap.begin(),
585          E = LI.BBMap.end(); I != E; ++I) {
586     assert(Loops.count(I->second) && "orphaned loop");
587     assert(I->second->contains(I->first) && "orphaned block");
588   }
589 }
590
591 void LoopInfo::getAnalysisUsage(AnalysisUsage &AU) const {
592   AU.setPreservesAll();
593   AU.addRequired<DominatorTree>();
594 }
595
596 void LoopInfo::print(raw_ostream &OS, const Module*) const {
597   LI.print(OS);
598 }
599
600 //===----------------------------------------------------------------------===//
601 // LoopBlocksDFS implementation
602 //
603
604 /// Traverse the loop blocks and store the DFS result.
605 /// Useful for clients that just want the final DFS result and don't need to
606 /// visit blocks during the initial traversal.
607 void LoopBlocksDFS::perform(LoopInfo *LI) {
608   LoopBlocksTraversal Traversal(*this, LI);
609   for (LoopBlocksTraversal::POTIterator POI = Traversal.begin(),
610          POE = Traversal.end(); POI != POE; ++POI) ;
611 }