remove the last set_fs() in common code, and remove it for x86 and powerpc v3

Segher Boessenkool segher at kernel.crashing.org
Fri Sep 11 03:15:42 AEST 2020


On Thu, Sep 10, 2020 at 03:31:53PM +0000, David Laight wrote:
> > > 	asm volatile ("" : "+r" (eax));
> > > 	// So here eax must contain the value set by the "xxxxx" instructions.
> > 
> > No, the register eax will contain the value of the eax variable.  In the
> > asm; it might well be there before or after the asm as well, but none of
> > that is guaranteed.
> 
> Perhaps not 'guaranteed', but very unlikely to be wrong.
> It doesn't give gcc much scope for not generating the desired code.

Wanna bet?  :-)

Correct is correct.  Anything else is not.


Segher


More information about the Linuxppc-dev mailing list