[PATCH] x86: fix handling of %eip/%rip
H.J. Lu
hjl@lucon.org
Wed Sep 26 13:03:00 GMT 2007
On Wed, Sep 26, 2007 at 07:51:35AM +0100, Jan Beulich wrote:
> >> --- 2007-09-25/opcodes/i386-reg.tbl 2007-09-25 16:27:55.000000000 +0200
> >> +++ 2007-09-25/opcodes/i386-reg.tbl 2007-09-25 17:19:30.000000000 +0200
> >> @@ -187,9 +187,10 @@ xmm12, RegXMM, RegRex, 4
> >> xmm13, RegXMM, RegRex, 5
> >> xmm14, RegXMM, RegRex, 6
> >> xmm15, RegXMM, RegRex, 7
> >> -// No type will make this register rejected for all purposes except
> >> -// for addressing. This saves creating one extra type for RIP.
> >> -rip, BaseIndex, 0, RegRip
> >> +// No type will make these registers rejected for all purposes except
> >> +// for addressing. This saves creating one extra type for RIP/EIP.
> >> +rip, BaseIndex, RegRex64, RegRip
> >> +eip, BaseIndex, RegRex64, RegEip
> >
> >Why is RegRex64 needed?
>
> In order to avoid these being considered a register name in 16/32-bit code.
> Either RegRex or RegRex64 would do here, but using RegRex64 seemed
> much safer due to the very few places where it is actually being used.
>
> OK to commit with that explanation?
>
OK. Thanks.
H.J.
More information about the Binutils
mailing list