Message ID | 20160610184237.GE7387@tucnak.redhat.com |
---|---|
State | New |
Headers | show |
On 06/10/16 20:42, Jakub Jelinek wrote: > > The second testcase FAILs on both x86_64 and i686, because it contains > no dg-options, therefore is compiled with -ansi -pedantic and that doesn't > allow GNU inline asm syntax. While looking at the testcase, I believe you > meant to make it executable, otherwise I don't understand why it has been > added in this form, and while at it, I've also fixed it for -masm=intel. > > Tested on x86_64-linux and i686-linux, committed to trunk. > > 2016-06-10 Jakub Jelinek <jakub@redhat.com> > > PR inline-asm/68843 > * gcc.target/i386/pr68843-2.c: Add dg-do run and empty dg-options. > (test): Add -masm=intel alternatives. > Oh, thanks for fixing that. Bernd.
--- gcc/testsuite/gcc.target/i386/pr68843-2.c.jj 2016-06-10 20:23:58.000000000 +0200 +++ gcc/testsuite/gcc.target/i386/pr68843-2.c 2016-06-10 20:38:01.336171681 +0200 @@ -1,10 +1,13 @@ +/* { dg-do run } */ +/* { dg-options "" } */ + int __attribute__((noinline, noclone)) test (double y) { int a, b; - asm ("fistpl (%1)\n\t" - "movl (%1), %0" + asm ("fistp{l (%1)| DWORD PTR [%1]}\n\t" + "mov{l (%1), %0| %0, DWORD PTR [%1]}" : "=r" (a) : "r" (&b), "t" (y) : "st");