aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2008-02-22 02:49:49 +0000
committerDevang Patel <dpatel@apple.com>2008-02-22 02:49:49 +0000
commit49cfe7018fdfe80aa1227a1fad5ba646f4d10fa7 (patch)
tree7803dcb8bfae0ced8f51bbe710a1ac415db93d59 /llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
parent997b3a65ca582632aa53dad60eb4a8f819da29b1 (diff)
downloadllvm-49cfe7018fdfe80aa1227a1fad5ba646f4d10fa7.zip
llvm-49cfe7018fdfe80aa1227a1fad5ba646f4d10fa7.tar.gz
llvm-49cfe7018fdfe80aa1227a1fad5ba646f4d10fa7.tar.bz2
Read and write getresult.
llvm-svn: 47471
Diffstat (limited to 'llvm/lib/Bitcode/Writer/BitcodeWriter.cpp')
-rw-r--r--llvm/lib/Bitcode/Writer/BitcodeWriter.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp b/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
index fe013e8..306433b 100644
--- a/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
+++ b/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
@@ -744,6 +744,11 @@ static void WriteInstruction(const Instruction &I, unsigned InstID,
Vals.push_back(VE.getValueID(I.getOperand(1)));
Vals.push_back(cast<CmpInst>(I).getPredicate());
break;
+ case Instruction::GetResult:
+ Code = bitc::FUNC_CODE_INST_GETRESULT;
+ PushValueAndType(I.getOperand(0), InstID, Vals, VE);
+ Vals.push_back(Log2_32(cast<GetResultInst>(I).getIndex())+1);
+ break;
case Instruction::Ret:
Code = bitc::FUNC_CODE_INST_RET;