[llvm-commits] [llvm] r95407 - /llvm/trunk/lib/Transforms/Utils/LoopSimplify.cpp
Dan Gohman
gohman at apple.com
Fri Feb 5 11:20:15 PST 2010
Author: djg
Date: Fri Feb 5 13:20:15 2010
New Revision: 95407
URL: http://llvm.org/viewvc/llvm-project?rev=95407&view=rev
Log:
Use a SmallSetVector instead of a SetVector; this code showed up as a
malloc caller in a profile.
Modified:
llvm/trunk/lib/Transforms/Utils/LoopSimplify.cpp
Modified: llvm/trunk/lib/Transforms/Utils/LoopSimplify.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Utils/LoopSimplify.cpp?rev=95407&r1=95406&r2=95407&view=diff
==============================================================================
--- llvm/trunk/lib/Transforms/Utils/LoopSimplify.cpp (original)
+++ llvm/trunk/lib/Transforms/Utils/LoopSimplify.cpp Fri Feb 5 13:20:15 2010
@@ -176,8 +176,9 @@
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);
More information about the llvm-commits
mailing list