From 37d30835f0592c32aa403e8ade88b8fc2ad2d612 Mon Sep 17 00:00:00 2001 From: Benjamin Kramer Date: Wed, 6 Jul 2011 16:43:46 +0000 Subject: [PATCH] SmallVectorize a critical vector. The small number of elements was determined by taking the median file length in clang+llvm and /usr/include on OS X with xcode installed. llvm-svn: 134496 --- clang/lib/Basic/SourceManager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clang/lib/Basic/SourceManager.cpp b/clang/lib/Basic/SourceManager.cpp index 92557a421f11..de709de9a22e 100644 --- a/clang/lib/Basic/SourceManager.cpp +++ b/clang/lib/Basic/SourceManager.cpp @@ -917,7 +917,7 @@ static void ComputeLineNumbers(Diagnostic &Diag, ContentCache *FI, // Find the file offsets of all of the *physical* source lines. This does // not look at trigraphs, escaped newlines, or anything else tricky. - std::vector LineOffsets; + llvm::SmallVector LineOffsets; // Line #1 starts at char 0. LineOffsets.push_back(0);