more m68k breakage on m68k-linux

Gunther Nikl gni@gecko.de
Tue Mar 2 10:42:00 GMT 2004


On Tue, Mar 02, 2004 at 09:53:05AM +0100, Richard Zidlicky wrote:
> On Tue, Mar 02, 2004 at 01:18:51AM +0100, Bernardo Innocenti wrote:
> > If I didn't increment FIRST_PSEUDO_REGISTER, register 25 would
> > be used both as the argptr and as a placeholder for some
> > temporary register, with very interesting consequences :-)
> 
> hm.. the problem I see is that the register allocator is initialised
> with random garbage. Eg FIXED_REGISTERS is 24 elts big, thus 
> initial_fixed_regs[] is also only 24 elts and in init_reg_sets() we
> copy a random 25th elt into fixed_regs[] and risk segfault.
> I am pretty sure more it results in more damage later on.

  Yes, that looks like a bug. i386.h has "argptr" included in
  FIXED_REGISTERS and gives it a nonzero value.

  Gunther
    



More information about the Gcc mailing list