diff options
author | Dan Gohman <gohman@apple.com> | 2010-02-05 19:20:15 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2010-02-05 19:20:15 +0000 |
commit | 17146baef5b79114f05e0f99fcba389f2764b65d (patch) | |
tree | 4a1699f0a158fcbd5acd7e36b71301d2fa145b37 /lib/Transforms | |
parent | a3a0db01217efc6403d90eec2a6ceb919f5031bc (diff) | |
download | external_llvm-17146baef5b79114f05e0f99fcba389f2764b65d.zip external_llvm-17146baef5b79114f05e0f99fcba389f2764b65d.tar.gz external_llvm-17146baef5b79114f05e0f99fcba389f2764b65d.tar.bz2 |
Use a SmallSetVector instead of a SetVector; this code showed up as a
malloc caller in a profile.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95407 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms')
-rw-r--r-- | lib/Transforms/Utils/LoopSimplify.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Transforms/Utils/LoopSimplify.cpp b/lib/Transforms/Utils/LoopSimplify.cpp index e81b779..57bab60 100644 --- a/lib/Transforms/Utils/LoopSimplify.cpp +++ b/lib/Transforms/Utils/LoopSimplify.cpp @@ -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); |