[llvm-commits] CVS: llvm/include/llvm/Analysis/LoopInfo.h

Devang Patel dpatel at apple.com
Tue Aug 29 15:29:33 PDT 2006



Changes in directory llvm/include/llvm/Analysis:

LoopInfo.h updated: 1.57 -> 1.58
---
Log message:

Do not rely on std::sort and std::erase to get list of unique
exit blocks. The output is dependent on addresses of basic block.

Add and use Loop::getUniqueExitBlocks.


---
Diffs of the changes:  (+6 -0)

 LoopInfo.h |    6 ++++++
 1 files changed, 6 insertions(+)


Index: llvm/include/llvm/Analysis/LoopInfo.h
diff -u llvm/include/llvm/Analysis/LoopInfo.h:1.57 llvm/include/llvm/Analysis/LoopInfo.h:1.58
--- llvm/include/llvm/Analysis/LoopInfo.h:1.57	Sun Jun 11 14:22:28 2006
+++ llvm/include/llvm/Analysis/LoopInfo.h	Tue Aug 29 17:29:16 2006
@@ -112,6 +112,12 @@
   ///
   void getExitBlocks(std::vector<BasicBlock*> &Blocks) const;
 
+  /// getUniqueExitBlocks - Return all unique successor blocks of this loop. 
+  /// These are the blocks _outside of the current loop_ which are branched to.
+  /// This assumes that loop is in canonical form.
+  ///
+  void getUniqueExitBlocks(std::vector<BasicBlock*> &ExitBlocks) const;
+
   /// getLoopPreheader - If there is a preheader for this loop, return it.  A
   /// loop has a preheader if there is only one edge to the header of the loop
   /// from outside of the loop.  If this is the case, the block branching to the






More information about the llvm-commits mailing list