unable to find a register to spill...

Jan Hubicka jh@suse.cz
Thu Apr 18 10:17:00 GMT 2002


> On Thu, Apr 18, 2002 at 06:26:27PM +0200, Jan Hubicka wrote:
> > It appears to be enought to add '?' to make reload
> > use second alternative and results in better code as well.
> 
> Why is this happening?  You shouldn't need to use ?.

Reload is looking for alternatives, computing cost and choosing first cheapest
one.  Since reload is not checking whether given alternative has free reigsters,
only computing the cost of needed moves, it finds 'a' to have same cost as 'r'
have.  I am not sure if we can teach the pricing scheme to compute the number
of spills needed to free up the space in register.    Perhaps we can just
try to figure out whether given class has some registers available and if not
increment losers, but I don't know how to determine it.

Honza
> 
> 
> r~



More information about the Gcc-patches mailing list