[LLVMbugs] [Bug 8937] New: [MC x86] gas knows a default size for stack access?
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sat Jan 8 16:03:36 PST 2011
http://llvm.org/bugs/show_bug.cgi?id=8937
Summary: [MC x86] gas knows a default size for stack access?
Product: new-bugs
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: new bugs
AssignedTo: unassignedbugs at nondot.org
ReportedBy: kaffeemonster at googlemail.com
CC: llvmbugs at cs.uiuc.edu
TOT at 123092
int foo(int c)
{
asm (
"push %0\n\t"
"and $3, (%%esp)\n\t"
"pop %0\n\t"
: "=r" (c)
: "0" (c)
);
return c;
}
$ gcc -c clang_and.c
gcc or more correct gas eats it
$ as --version
GNU assembler (GNU Binutils) 2.20.1.20100303
$ clang -c clang_and.c
clang_and.c:4:14: error: ambiguous instructions require an explicit suffix
(could be 'andb', 'andw', 'andl', or 'andq')
"push %0\n\t"
^
<inline asm>:2:2: note: instantiated into assembly here
and $3, (%esp)
^
1 error generated.
clang/llvm does not
Greetings
Jan
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list