From 7c6c55db4df35c9e0bbff89ceec52b0504862d7d Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Tue, 21 Aug 2007 16:39:43 +0000 Subject: [PATCH] No need to hardcode SmallVector size. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41228 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Analysis/LoopInfo.h | 6 +++--- lib/Analysis/LoopInfo.cpp | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/include/llvm/Analysis/LoopInfo.h b/include/llvm/Analysis/LoopInfo.h index 7dcfb60a374..acb5fd6c7a4 100644 --- a/include/llvm/Analysis/LoopInfo.h +++ b/include/llvm/Analysis/LoopInfo.h @@ -112,18 +112,18 @@ public: /// outside of the loop. These are the blocks _inside of the current loop_ /// which branch out. The returned list is always unique. /// - void getExitingBlocks(SmallVector &Blocks) const; + void getExitingBlocks(SmallVectorImpl &Blocks) const; /// getExitBlocks - Return all of the successor blocks of this loop. These /// are the blocks _outside of the current loop_ which are branched to. /// - void getExitBlocks(SmallVector &Blocks) const; + void getExitBlocks(SmallVectorImpl &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(SmallVector &ExitBlocks) const; + void getUniqueExitBlocks(SmallVectorImpl &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 diff --git a/lib/Analysis/LoopInfo.cpp b/lib/Analysis/LoopInfo.cpp index 877bd4ae676..e479edc6473 100644 --- a/lib/Analysis/LoopInfo.cpp +++ b/lib/Analysis/LoopInfo.cpp @@ -350,7 +350,7 @@ void LoopInfo::removeBlock(BasicBlock *BB) { /// outside of the loop. These are the blocks _inside of the current loop_ /// which branch out. The returned list is always unique. /// -void Loop::getExitingBlocks(SmallVector &ExitingBlocks) const { +void Loop::getExitingBlocks(SmallVectorImpl &ExitingBlocks) const { // Sort the blocks vector so that we can use binary search to do quick // lookups. std::vector LoopBBs(block_begin(), block_end()); @@ -369,7 +369,7 @@ void Loop::getExitingBlocks(SmallVector &ExitingBlocks) const { /// getExitBlocks - Return all of the successor blocks of this loop. These /// are the blocks _outside of the current loop_ which are branched to. /// -void Loop::getExitBlocks(SmallVector &ExitBlocks) const { +void Loop::getExitBlocks(SmallVectorImpl &ExitBlocks) const { // Sort the blocks vector so that we can use binary search to do quick // lookups. std::vector LoopBBs(block_begin(), block_end()); @@ -387,7 +387,7 @@ void Loop::getExitBlocks(SmallVector &ExitBlocks) const { /// are the blocks _outside of the current loop_ which are branched to. This /// assumes that loop is in canonical form. // -void Loop::getUniqueExitBlocks(SmallVector &ExitBlocks) const { +void Loop::getUniqueExitBlocks(SmallVectorImpl &ExitBlocks) const { // Sort the blocks vector so that we can use binary search to do quick // lookups. std::vector LoopBBs(block_begin(), block_end());