summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/AsmWriter.cpp
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2006-12-31 22:17:01 +0000
committerReid Spencer <rspencer@reidspencer.com>2006-12-31 22:17:01 +0000
commit9cfa4e84598828d4d1c6ae33221b774ff4e8a288 (patch)
tree21109dfe46bc1c2075dacf38805c59f8a93868e6 /llvm/lib/VMCore/AsmWriter.cpp
parentd0da3e200a363e97b19f116d75e12d756b014957 (diff)
downloadbcm5719-llvm-9cfa4e84598828d4d1c6ae33221b774ff4e8a288.tar.gz
bcm5719-llvm-9cfa4e84598828d4d1c6ae33221b774ff4e8a288.zip
Fix a cut-and-paste bug for processing of InvokeInst parameter attributes.
The lookup of parameter attributes was offset by two because of the additional operands in an invoke instruction. llvm-svn: 32801
Diffstat (limited to 'llvm/lib/VMCore/AsmWriter.cpp')
-rw-r--r--llvm/lib/VMCore/AsmWriter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/VMCore/AsmWriter.cpp b/llvm/lib/VMCore/AsmWriter.cpp
index 317eb8e0aac..a46adabd1e1 100644
--- a/llvm/lib/VMCore/AsmWriter.cpp
+++ b/llvm/lib/VMCore/AsmWriter.cpp
@@ -1237,8 +1237,8 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
if (op > 3)
Out << ',';
writeOperand(I.getOperand(op), true);
- if (FTy->getParamAttrs(op) != FunctionType::NoAttributeSet)
- Out << " " << FTy->getParamAttrsText(FTy->getParamAttrs(op));
+ if (FTy->getParamAttrs(op-2) != FunctionType::NoAttributeSet)
+ Out << " " << FTy->getParamAttrsText(FTy->getParamAttrs(op-2));
}
Out << " )\n\t\t\tto";
OpenPOWER on IntegriCloud