This is the mail archive of the gcc-patches@gcc.gnu.org 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]

Re: patch to omit the frame pointer from leaf functions (version 2)




  In message <199810172009.QAA05926@jwlab.FEITH.COM>you write:
  > Maybe the thing to do is to fix gdb so it handles frameless leaf functions
  > for the i386, make the optimization dependent on CAN_DEBUG_LEAF_WITHOUT_FP,
  > and have i386.h define this new macro.
Agreed, and I don't think we need to fix all the ports at once.  Certainly
start with the x86, then fault in code for other ports when possible.

I've done his kind of work on few gdb ports (pa, mn102, mn103).  The x86
is a little more difficult, but I don't think it's that much worse.

If you want, I can probably put you in touch with some gdb folks that can
give you a helping hand on the gdb bits.

  > My change to reload1.c causes the frame pointer to be eliminated whenever 
  > current_function_sp_is_unchanging is set.  The comment says that using
  > the frame pointer as a base reg in this situation is undesirable.  My
  > change to pa.c was to realize that the frame pointer is eliminated if
  > either flag_omit_frame_pointer or current_function_sp_is_unchanging is
  > set so using the frame pointer as a base register should only be done if
  > ! (flag_omit_frame_pointer || current_function_sp_is_unchanging).
  > Did I miss understand something?
No, I missed something.  Ignore my comments.

jeff


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