Registerized function parameters and related things.

Fergus Henderson fjh@cs.mu.OZ.AU
Mon Dec 2 22:53:00 GMT 2002


On 02-Dec-2002, Fabio Alemagna <falemagn@studenti.unina.it> wrote:
> 
> Another reason is to speed up function calling, by putting the libbase in
> a register. Granted, we could do that by using the libbase as 1st
> parameter and using regparm(1), but that would put the libbase in eax,
> whilst I want it to go in ecx because eax should be aliased to d0 (always
> themost common register for 1st function parameters, and also the 1st
> return register, just like eax) and ebx should be aliased to d1, for the
> same reasons (just substitute 1st with 2nd).

Is libbase a global?  If so, would GCC's global register variable
extension help here?

-- 
Fergus Henderson <fjh@cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.



More information about the Gcc mailing list