diff mbox

Fix complex lowering with inline asm (PR tree-optimization/55921)

Message ID m2y5fzub0d.fsf@igel.home
State New
Headers show

Commit Message

Andreas Schwab Jan. 11, 2013, 1:04 p.m. UTC
Jakub Jelinek <jakub@redhat.com> writes:

> +  __asm ("" : "=r" (cf) : "0" (ucf1.ll));

gcc/testsuite/gcc.c-torture/compile/pr55921.c:17:3: error: 'asm' operand has impossible constraints
gcc/testsuite/gcc.c-torture/compile/pr55921.c:19:3: error: 'asm' operand has impossible constraints

OK?  This still triggers the original bug.

Andreas.

2013-01-11  Andreas Schwab  <schwab@linux-m68k.org>

	* gcc.c-torture/compile/pr55921.c: Don't use matching constraints.

Comments

Richard Biener Jan. 11, 2013, 1:03 p.m. UTC | #1
On Fri, 11 Jan 2013, Andreas Schwab wrote:

> Jakub Jelinek <jakub@redhat.com> writes:
> 
> > +  __asm ("" : "=r" (cf) : "0" (ucf1.ll));
> 
> gcc/testsuite/gcc.c-torture/compile/pr55921.c:17:3: error: 'asm' operand has impossible constraints
> gcc/testsuite/gcc.c-torture/compile/pr55921.c:19:3: error: 'asm' operand has impossible constraints
> 
> OK?  This still triggers the original bug.

Ok.

Thanks,
Richard.

> Andreas.
> 
> 2013-01-11  Andreas Schwab  <schwab@linux-m68k.org>
> 
> 	* gcc.c-torture/compile/pr55921.c: Don't use matching constraints.
> 
> diff --git a/gcc/testsuite/gcc.c-torture/compile/pr55921.c b/gcc/testsuite/gcc.c-torture/compile/pr55921.c
> index 8ac9e9b..94b7bce 100644
> --- a/gcc/testsuite/gcc.c-torture/compile/pr55921.c
> +++ b/gcc/testsuite/gcc.c-torture/compile/pr55921.c
> @@ -14,8 +14,8 @@ foo (ucf *in, ucf *out, _Complex float r)
>    _Complex float cf;
>  
>    ucf1.ll = in[i].ll;
> -  __asm ("" : "=r" (cf) : "0" (ucf1.ll));
> +  __asm ("" : "=r" (cf) : "r" (ucf1.ll));
>    cf *= r;
> -  __asm ("" : "=r" (ucf1.ll) : "0" (cf));
> +  __asm ("" : "=r" (ucf1.ll) : "r" (cf));
>    out[i].ll = ucf1.ll;
>  }
> 
>
diff mbox

Patch

diff --git a/gcc/testsuite/gcc.c-torture/compile/pr55921.c b/gcc/testsuite/gcc.c-torture/compile/pr55921.c
index 8ac9e9b..94b7bce 100644
--- a/gcc/testsuite/gcc.c-torture/compile/pr55921.c
+++ b/gcc/testsuite/gcc.c-torture/compile/pr55921.c
@@ -14,8 +14,8 @@  foo (ucf *in, ucf *out, _Complex float r)
   _Complex float cf;
 
   ucf1.ll = in[i].ll;
-  __asm ("" : "=r" (cf) : "0" (ucf1.ll));
+  __asm ("" : "=r" (cf) : "r" (ucf1.ll));
   cf *= r;
-  __asm ("" : "=r" (ucf1.ll) : "0" (cf));
+  __asm ("" : "=r" (ucf1.ll) : "r" (cf));
   out[i].ll = ucf1.ll;
 }