back out r101423 and r101397, they break llvm-gcc self-host on darwin10

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101434 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Gabor Greif
2010-04-16 01:16:20 +00:00
parent 5f0378251c
commit 607a7ab3da
44 changed files with 586 additions and 577 deletions
+5 -6
View File
@@ -1847,7 +1847,6 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
default: Out << " cc" << CI->getCallingConv(); break;
}
Operand = CI->getCalledValue();
const PointerType *PTy = cast<PointerType>(Operand->getType());
const FunctionType *FTy = cast<FunctionType>(PTy->getElementType());
const Type *RetTy = FTy->getReturnType();
@@ -1871,10 +1870,10 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
writeOperand(Operand, true);
}
Out << '(';
for (unsigned op = 0, Eop = CI->getNumOperands() - 1; op < Eop; ++op) {
if (op > 0)
for (unsigned op = 1, Eop = I.getNumOperands(); op < Eop; ++op) {
if (op > 1)
Out << ", ";
writeParamOperand(CI->getOperand(op), PAL.getParamAttributes(op + 1));
writeParamOperand(I.getOperand(op), PAL.getParamAttributes(op));
}
Out << ')';
if (PAL.getFnAttributes() != Attribute::None)
@@ -1918,10 +1917,10 @@ void AssemblyWriter::printInstruction(const Instruction &I) {
writeOperand(Operand, true);
}
Out << '(';
for (unsigned op = 0, Eop = II->getNumOperands() - 3; op < Eop; ++op) {
for (unsigned op = 0, Eop = I.getNumOperands() - 3; op < Eop; ++op) {
if (op)
Out << ", ";
writeParamOperand(II->getOperand(op), PAL.getParamAttributes(op + 1));
writeParamOperand(I.getOperand(op), PAL.getParamAttributes(op + 1));
}
Out << ')';