look at the right operand when increasing the size of an asm output,

this fixes http://llvm.org/bugs/show_bug.cgi?id=3373#c20

llvm-svn: 70685
This commit is contained in:
Chris Lattner 2009-05-03 09:05:53 +00:00
parent ccf6183687
commit 61af27860d
2 changed files with 14 additions and 3 deletions

View File

@ -848,10 +848,8 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) {
for (InputNo = 0; InputNo != S.getNumInputs(); ++InputNo) {
TargetInfo::ConstraintInfo &Input = InputConstraintInfos[InputNo];
if (Input.hasTiedOperand() &&
Input.getTiedOperand() == i) {
InputNo = i;
Input.getTiedOperand() == i)
break;
}
}
assert(InputNo != S.getNumInputs() && "Didn't find matching input!");

View File

@ -77,6 +77,19 @@ unsigned char t13(unsigned input) {
return output;
}
struct large {
int x[1000];
};
unsigned long t15(int x, struct large *P) {
__asm__("xyz "
: "=r" (x)
: "m" (*P), "0" (x));
return x;
}
// bitfield destination of an asm.
struct S {