Use a SmallSetVector instead of a SetVector; this code showed up as a
authorDan Gohman <gohman@apple.com>
Fri, 5 Feb 2010 19:20:15 +0000 (19:20 +0000)
committerDan Gohman <gohman@apple.com>
Fri, 5 Feb 2010 19:20:15 +0000 (19:20 +0000)
malloc caller in a profile.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95407 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Utils/LoopSimplify.cpp

index e81b77974abb8a91b29ac2eb24b5634a414c2840..57bab60e6b1c96dbec597805a01906f8eb6bf06e 100644 (file)
@@ -176,8 +176,9 @@ ReprocessLoop:
   SmallVector<BasicBlock*, 8> ExitBlocks;
   L->getExitBlocks(ExitBlocks);
     
-  SetVector<BasicBlock*> ExitBlockSet(ExitBlocks.begin(), ExitBlocks.end());
-  for (SetVector<BasicBlock*>::iterator I = ExitBlockSet.begin(),
+  SmallSetVector<BasicBlock *, 8> ExitBlockSet(ExitBlocks.begin(),
+                                               ExitBlocks.end());
+  for (SmallSetVector<BasicBlock *, 8>::iterator I = ExitBlockSet.begin(),
          E = ExitBlockSet.end(); I != E; ++I) {
     BasicBlock *ExitBlock = *I;
     for (pred_iterator PI = pred_begin(ExitBlock), PE = pred_end(ExitBlock);