Closed isanbard closed 2 years ago
mentioned in issue llvm/llvm-project#1234
mentioned in issue llvm/llvm-bugzilla-archive#1374
Fixed. Patch here: http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20070430/048747.html There are several other required patches to go along with this though.
Testcase here: CodeGen/PowerPC/2007-04-30-InlineAsmEarlyClobber.ll
-Chris
Reduced testcase:
long long test(int A, int B, int C) { unsigned X, Y; asm ("subf%I3c %1,%4,%3\nsubfze %0,%2" : "=r" (X), "=&r" (Y) : "r" (A), "rI" (B), "r" (C)); return ((long long)Y << 32) | X; }
We compile this to:
_test:
subfc r3,r5,r4
subfze r4,r3
# InlineAsm End
stw r3, -4(r1)
blr
Note that the first instruction clobbers r3 before the second instruction uses it.
-Chris
assigned to @lattner
Extended Description
I've attached the .ll file that aborts when run. It's something to do with the inline assembly thingy.
On the plus side, GMP compiled! :-)