mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Paper over CBackend/2004-08-09-va-end-null.ll
Note that this indicates a serious problem with the way we are emitting varargs, but this should not be properly fixed until after 1.3. This patch SHOULD go into 1.3. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15602 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
008fad0236
commit
f8e6f4f776
@ -1390,9 +1390,13 @@ void CWriter::visitCallInst(CallInst &I) {
|
|||||||
Out << ")";
|
Out << ")";
|
||||||
return;
|
return;
|
||||||
case Intrinsic::vaend:
|
case Intrinsic::vaend:
|
||||||
Out << "va_end(*(va_list*)&";
|
if (!isa<ConstantPointerNull>(I.getOperand(1))) {
|
||||||
writeOperand(I.getOperand(1));
|
Out << "va_end(*(va_list*)&";
|
||||||
Out << ")";
|
writeOperand(I.getOperand(1));
|
||||||
|
Out << ")";
|
||||||
|
} else {
|
||||||
|
Out << "va_end(*(va_list*)0)";
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
case Intrinsic::vacopy:
|
case Intrinsic::vacopy:
|
||||||
Out << "0;";
|
Out << "0;";
|
||||||
|
@ -1390,9 +1390,13 @@ void CWriter::visitCallInst(CallInst &I) {
|
|||||||
Out << ")";
|
Out << ")";
|
||||||
return;
|
return;
|
||||||
case Intrinsic::vaend:
|
case Intrinsic::vaend:
|
||||||
Out << "va_end(*(va_list*)&";
|
if (!isa<ConstantPointerNull>(I.getOperand(1))) {
|
||||||
writeOperand(I.getOperand(1));
|
Out << "va_end(*(va_list*)&";
|
||||||
Out << ")";
|
writeOperand(I.getOperand(1));
|
||||||
|
Out << ")";
|
||||||
|
} else {
|
||||||
|
Out << "va_end(*(va_list*)0)";
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
case Intrinsic::vacopy:
|
case Intrinsic::vacopy:
|
||||||
Out << "0;";
|
Out << "0;";
|
||||||
|
Loading…
Reference in New Issue
Block a user