strange compiling problem
Jamie Lokier
jamie@shareable.org
Sun Sep 7 16:06:00 GMT 2003
Andrew Pinski wrote:
> > :"=m"(*&ra)
> > :"0"(*&ra), "m"(*&rb)
>
>
> Even better, I think this is where the problem is any way:
> :"+m"(*&ra)
> : "m"(*&rb)
>
> And change all %2 to %1 and %1 to %0.
> Note the + means that ra is being read from and written to.
> Almost every one wants to write it as the way you had it
> though for some reason.
It's because older GCC didn't support the "+" syntax in asms, and
current GCC supports either and automatically converts the first form
into the second one, in an asm.
-- Jamie
More information about the Gcc
mailing list