summaryrefslogtreecommitdiff
path: root/lib/Bitcode/Writer/BitcodeWriter.cpp
diff options
context:
space:
mode:
authorMichael Ilseman <milseman@apple.com>2012-12-03 21:29:36 +0000
committerMichael Ilseman <milseman@apple.com>2012-12-03 21:29:36 +0000
commitdbd7b95ed415a7d9fd5f53d9f811906c58912c60 (patch)
tree49764e1e9db57f909693f2020fe05c3669a112e4 /lib/Bitcode/Writer/BitcodeWriter.cpp
parent7eafc3e7be067709c6fcdae7b7fc4994c7ec2377 (diff)
downloadllvm-dbd7b95ed415a7d9fd5f53d9f811906c58912c60.tar.gz
llvm-dbd7b95ed415a7d9fd5f53d9f811906c58912c60.tar.bz2
llvm-dbd7b95ed415a7d9fd5f53d9f811906c58912c60.tar.xz
Since this SmallVector immediately grows on the next line, don't waste stack space. SmallVector is still needed due to existing APIs growing their arguments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169157 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode/Writer/BitcodeWriter.cpp')
-rw-r--r--lib/Bitcode/Writer/BitcodeWriter.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Bitcode/Writer/BitcodeWriter.cpp b/lib/Bitcode/Writer/BitcodeWriter.cpp
index bbc9c834ec..2ea9cbd6f4 100644
--- a/lib/Bitcode/Writer/BitcodeWriter.cpp
+++ b/lib/Bitcode/Writer/BitcodeWriter.cpp
@@ -1939,7 +1939,7 @@ static void EmitDarwinBCHeaderAndTrailer(SmallVectorImpl<char> &Buffer,
/// WriteBitcodeToFile - Write the specified module to the specified output
/// stream.
void llvm::WriteBitcodeToFile(const Module *M, raw_ostream &Out) {
- SmallVector<char, 1024> Buffer;
+ SmallVector<char, 0> Buffer;
Buffer.reserve(256*1024);
// If this is darwin or another generic macho target, reserve space for the