-
Notifications
You must be signed in to change notification settings - Fork 15.1k
Closed
Labels
bugzillaIssues migrated from bugzillaIssues migrated from bugzilladuplicateResolved as duplicateResolved as duplicate
Description
| Bugzilla Link | 2102 |
| Resolution | DUPLICATE |
| Resolved on | Feb 26, 2008 17:15 |
| Version | trunk |
| OS | Linux |
| Attachments | LLVM Assembly Code that exhibits the problem |
| Reporter | LLVM Bugzilla Contributor |
Extended Description
The C Backend does not correctly generate inline asm that uses constants.
For example, it takes this:
%tmp1 = call i32 asm sideeffect "add $$8, $0\0A", "={ax},{dirflag},{fpsr},~{flags}"( ) nounwind ; [#uses=1]
And translates it into this:
asm volatile ("add %%8, %0\n"
:"=a"(llvm_cbe_tmp1)
:);
The 8 should be "$8" and not "%%8" in the output.
An LLVM assembly case is attached. To reproduce:
llvm-as -o test.bc test.ll
llc -march=c -f -o test.cbe.c test.bc
Metadata
Metadata
Assignees
Labels
bugzillaIssues migrated from bugzillaIssues migrated from bugzilladuplicateResolved as duplicateResolved as duplicate