summaryrefslogtreecommitdiff
path: root/lib/Bitcode/Reader
diff options
context:
space:
mode:
authorNick Lewycky <nicholas@mxc.ca>2010-02-25 08:30:17 +0000
committerNick Lewycky <nicholas@mxc.ca>2010-02-25 08:30:17 +0000
commit9a49f1552db7e2ce24a03ec068b17db8a238856d (patch)
treec9118bf4a44833374e486895fbc55231de596ba4 /lib/Bitcode/Reader
parent04db82d2ba5d9d8e935de82a465b1de5ea7cdf69 (diff)
downloadllvm-9a49f1552db7e2ce24a03ec068b17db8a238856d.tar.gz
llvm-9a49f1552db7e2ce24a03ec068b17db8a238856d.tar.bz2
llvm-9a49f1552db7e2ce24a03ec068b17db8a238856d.tar.xz
Make the side-numbering of instructions used by metadata (which is needed to
keep track of instructions that return void) per-function. This fixes PR5278. This breaks backwards compatibility with the metadata format. That's okay because we haven't released the metadata bitcode yet. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97132 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode/Reader')
-rw-r--r--lib/Bitcode/Reader/BitcodeReader.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Bitcode/Reader/BitcodeReader.cpp b/lib/Bitcode/Reader/BitcodeReader.cpp
index 4ac5069eb4..a32883720b 100644
--- a/lib/Bitcode/Reader/BitcodeReader.cpp
+++ b/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -1622,6 +1622,7 @@ bool BitcodeReader::ParseFunctionBody(Function *F) {
if (Stream.EnterSubBlock(bitc::FUNCTION_BLOCK_ID))
return Error("Malformed block record");
+ InstructionList.clear();
unsigned ModuleValueListSize = ValueList.size();
// Add all the function arguments to the value table.