Changing the treatment of the MIPS HI and LO registers

Maciej W. Rozycki macro@linux-mips.org
Tue May 27 21:45:00 GMT 2008


On Tue, 27 May 2008, Richard Sandiford wrote:

> We can keep "hi" as a recognised register name for backwards compatibility
> in clobber lists.  (A lesson learned from removing the old on-the-side
> "hilo" register, which had even more headaches than this one.  After
> that change, quite a few linux clobber lists had to be conditional on
> the compiler version -- sorry about that!)
[...]
> Comments?  I'll hold off applying this for 48 hours to see if there
> are any.  If the patch goes in, I'll add something to the 4.4
> changes page as well.

 So how do you want to address the compatibility issue with Linux on this 
occasion?  It uses both the "h" and the "l" constraint in a few places.  

 If the semantics is to be changed I think the "l" constraint should be
removed altogether so that code that makes use of it breaks loudly.  We
have had the "x" constraint to refer to the HI/LO pair as a whole for a
while now.

 You could resurrect the "accum" register since you are creating one.

 What about the DSP accumulators?

  Maciej



More information about the Gcc-patches mailing list