A bug in IA32 assembler

Alan Modra amodra@bigpond.net.au
Fri Jun 29 00:48:00 GMT 2001


On Fri, Jun 29, 2001 at 12:15:56AM -0700, H . J . Lu wrote:
> On Thu, Jun 28, 2001 at 11:03:03PM -0700, Richard Henderson wrote:
> > On Thu, Jun 28, 2001 at 07:03:30PM -0700, H . J . Lu wrote:
> > > Have you tried it on the testcase I enclosed? It doesn't work for me.
> > 
> > No.  At least in the message I saw the test case was not
> > complete.  Perhaps I've already deleted the original.
> 
> I am enclosing it again. Try to compile and run it on a P/III
> machine.
> 
> > 
> > In either case, I _guarantee_ that the asm I quoted is wrong,
> > even if the replacement I suggested isn't right.
> > 
> > 
> 
> This one:
> 
>         asm("movaps (%0),%%xmm0"                                //SSE
>         :
>         :"g"(A));

is wrong.  You can't use "g", because movaps doesn't take immediates,
or general registers for that matter.

Try
	asm ("movaps %0,%%xmm0: : "m" (A));

also getting rid of the redundant '()' which is only confusing the issue.

Alan



More information about the Binutils mailing list