Number of registers on x86
Bo Thorsen
bo@sonofthor.dk
Mon Jan 29 22:57:00 GMT 2001
On Mon, 29 Jan 2001, Daniel Berlin wrote:
> Can we please lie and say we have 32 GP registers on x86?
> Why, you ask?
>
> Well, there are 40 universal temporaries that are used by the hardware
> register renaming.
> Everything but floating status word, and floating point control word, can
> be renamed.
>
> Intel's compiler (IIRC), and SML/NJ do this (I'm positive about this one),
> and it improves performance, and helps to eliminate a lot of worthless
> spills.
> They just map them back into the 8 registers right before emitting.
Does anyone know how the new Amiga assembler works? They have an
infinite(!) amount of registers which the runtime schedules to use the
registers available on the chip the code is running on. It might be
interesting to see if this algorithm could lead to better use of registers
on compile time also.
Bo.
--
Bo Thorsen | Lahnsgade 31, st.
Free software developer | 5000 Odense C
SuSE Labs | Denmark
More information about the Gcc
mailing list