[llvm-commits] [llvm] r124065 - /llvm/trunk/include/llvm/Analysis/DominatorInternals.h

Cameron Zwarich zwarich at apple.com
Sat Jan 22 22:54:22 PST 2011


Author: zwarich
Date: Sun Jan 23 00:54:22 2011
New Revision: 124065

URL: http://llvm.org/viewvc/llvm-project?rev=124065&view=rev
Log:
Convert a std::vector to a SmallVector for another 5.4% speedup on domtree.

Modified:
    llvm/trunk/include/llvm/Analysis/DominatorInternals.h

Modified: llvm/trunk/include/llvm/Analysis/DominatorInternals.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Analysis/DominatorInternals.h?rev=124065&r1=124064&r2=124065&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Analysis/DominatorInternals.h (original)
+++ llvm/trunk/include/llvm/Analysis/DominatorInternals.h Sun Jan 23 00:54:22 2011
@@ -53,8 +53,8 @@
 #else
   bool IsChildOfArtificialExit = (N != 0);
 
-  std::vector<std::pair<typename GraphT::NodeType*,
-                        typename GraphT::ChildIteratorType> > Worklist;
+  SmallVector<std::pair<typename GraphT::NodeType*,
+                        typename GraphT::ChildIteratorType>, 32> Worklist;
   Worklist.push_back(std::make_pair(V, GraphT::child_begin(V)));
   while (!Worklist.empty()) {
     typename GraphT::NodeType* BB = Worklist.back().first;





More information about the llvm-commits mailing list