diff --git a/include/llvm/Analysis/DominatorInternals.h b/include/llvm/Analysis/DominatorInternals.h index 0419688a53b..654289e6305 100644 --- a/include/llvm/Analysis/DominatorInternals.h +++ b/include/llvm/Analysis/DominatorInternals.h @@ -116,7 +116,7 @@ unsigned DFSPass(DominatorTreeBase& DT, template void Compress(DominatorTreeBase& DT, typename GraphT::NodeType *VIn) { - std::vector Work; + SmallVector Work; SmallPtrSet Visited; typename DominatorTreeBase::InfoRec &VInVAInfo = DT.Info[DT.Vertex[DT.Info[VIn].Ancestor]]; diff --git a/lib/Transforms/InstCombine/InstructionCombining.cpp b/lib/Transforms/InstCombine/InstructionCombining.cpp index 47519fbaef9..de409d1ccee 100644 --- a/lib/Transforms/InstCombine/InstructionCombining.cpp +++ b/lib/Transforms/InstCombine/InstructionCombining.cpp @@ -1032,10 +1032,8 @@ static bool AddReachableCodeToWorklist(BasicBlock *BB, bool MadeIRChange = false; SmallVector Worklist; Worklist.push_back(BB); - - std::vector InstrsForInstCombineWorklist; - InstrsForInstCombineWorklist.reserve(128); + SmallVector InstrsForInstCombineWorklist; SmallPtrSet FoldedConstants; do {