new-regalloc vs alpha

Michael Meissner meissner@cygnus.com
Fri Feb 2 09:04:00 GMT 2001


On Thu, Feb 01, 2001 at 12:47:31PM -0500, Daniel Berlin wrote:
> 
> 
> On Tue, 30 Jan 2001, Richard Henderson wrote:
> 
> > On Tue, Jan 30, 2001 at 05:33:23PM -0500, Daniel Berlin wrote:
> > > > 	(set (reg:DI foo) (mem:DI (reg:DI $f10)))
> > ...
> > > Shouldn't reload fix this for us though?
> >
> > Yes, it should.  And if it knows what sort of instruction this is,
> > it _will_ fix it up.  The problem arises only when the insn code
> > is unknown (step one in the outlined scenario), which means that
> > it has no operand locations or constraints to work with.
> >
> 
> You know what's ironic?
> This (the above insn) happens because we try to follow the register
> allocation order, which says to try the float regs first, and since they
> seem okay to us, we do.
> It also causes us to not find spill regs available in the float_reg class
> on powerpc occasionally.

Are you following the constraints '*', '?', and '!' which on the alpha at least
uses '*' to say that to ignore that particular alternative in terms of register
allocation (but reload can if needed).

> If i ignore the allocation order preference, both the above problem, and
> the inability to find spill regs for the FLOAT_REGS class on powerpc, go
> away.
> 
> Maybe I should just ignore the allocation order, since all it seems to do
> is cause us problems?

No, no, no.  There arre often times good reasons why the alloc order is
chosen (for example use of %eax in the x86 port usually results in a smaller
instruction).  As a debugging switch, a -fignore-reg-alloc-order might help a
backend maintainer tune the port.

-- 
Michael Meissner, Red Hat, Inc.  (GCC group)
PMB 198, 174 Littleton Road #3, Westford, Massachusetts 01886, USA
Work:	  meissner@redhat.com		phone: +1 978-486-9304
Non-work: meissner@spectacle-pond.org	fax:   +1 978-692-4482


More information about the Gcc-patches mailing list