diff options
author | Devang Patel <dpatel@apple.com> | 2008-02-23 01:04:26 +0000 |
---|---|---|
committer | Devang Patel <dpatel@apple.com> | 2008-02-23 01:04:26 +0000 |
commit | 377e04b926f187b036b7b7a536f69b6b5d5785e9 (patch) | |
tree | abaef981bfbefbfa1a10d75a9e0bbe826d5ee238 /lib/VMCore | |
parent | 28c9fc630c02088ebb41c7a77c2743e0b019a322 (diff) | |
download | external_llvm-377e04b926f187b036b7b7a536f69b6b5d5785e9.zip external_llvm-377e04b926f187b036b7b7a536f69b6b5d5785e9.tar.gz external_llvm-377e04b926f187b036b7b7a536f69b6b5d5785e9.tar.bz2 |
print getresult operand and its type directly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47514 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore')
-rw-r--r-- | lib/VMCore/AsmWriter.cpp | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/lib/VMCore/AsmWriter.cpp b/lib/VMCore/AsmWriter.cpp index adbcd78..55d037d 100644 --- a/lib/VMCore/AsmWriter.cpp +++ b/lib/VMCore/AsmWriter.cpp @@ -1292,17 +1292,7 @@ void AssemblyWriter::printInstruction(const Instruction &I) { writeOperand(I.getOperand(op+1), false); Out << " ]"; } } else if (const GetResultInst *GRI = dyn_cast<GetResultInst>(&I)) { - const StructType *STy = cast<StructType>(I.getOperand(0)->getType()); - unsigned NumElems = STy->getNumElements(); - Out << " {"; - for (unsigned i = 0; i < NumElems; ++i) { - if (i) - Out << ","; - Out << " "; - printType(STy->getElementType(i)); - } - Out << " }"; - writeOperand(I.getOperand(0), false); + writeOperand(I.getOperand(0), true); Out << ", " << GRI->getIndex(); } else if (isa<ReturnInst>(I) && !Operand) { Out << " void"; |