This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: m68k patch reviews

On Thursday 21 August 2003 09:53, Gunther Nikl wrote:

>  I just noticed your patches and I guess they will cause some headaches for
>  me. Especially these:
>  The AmigaOS port modified INITIAL_FRAME_POINTER_OFFSET for __saveds and
>  I added code for attribute handling (eg. generic regparm support for m68k)
>  Unfortunately, the AmigaOS port has a "interrupt" attribute too, but with
>  a different meaning :-(

 I see. I've used GCC on the Amiga for quite some time and I've always
wanted to see GeekGadget patches merged into GCC. Several years ago I even
had a harsh discussion with RMS in person about that :-)

IIRC, the __saveds attribute told the compiler to reload the data section
pointer in A4 at function prologue time.

A very clean way to handle this would be adding a new test in m68k_save_reg():

   if (saveds_function && (reg == DS_REGNO))
      return true;

Then you'll get the old A4 saved on the stack along with other registers automatically,
without the need to fiddle with the frame size.

As for the attribute((interrupt)), wan't it used the same way on the Amiga? Or perhaps
it did only take care of callee-saved registers without using RTE?

In the latter case, I think we could rename this attribute to 'interrupt_handler' and
leave the Amiga semantics intact. Even though Amiga support is not yet in mainline,
I know there is a ton of Amiga code relying on this behaviour and we don't want to
break it in the future.

  // Bernardo Innocenti - Develer S.r.l., R&D dept.

Please don't send Word attachments -

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]