This is the mail archive of the gcc@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]
Other format: [Raw text]

Re: Changing the frame layout of H8 port to reduce code size


In message <m3oesplajc.fsf@gossamer.airs.com>, Ian Lance Taylor writes:
 >Kazu Hirata <kazu@cs.umass.edu> writes:
 >
 >> I am thinking about changing the frame layout of H8 port to reduce
 >> code size and would like to ask for comments.
 >
 >You didn't mention whether you've checked the debugger.  Does gdb
 >still work fine after such a change, or would it need some
 >modifications?
The only part of GDB that is likely going to need to be updated would be
the code which digs saved registers out of the frame.

It's been a _long_ time since I looked at that code and I have no idea
off the top of my head if it was implemented robustly enough to handle
this change.

Though at first glance I would like to hope GDB would work unchanged
since finding the saved registers in the new layout amounts to finding
the saved registers in the old layout in cases where there are no locals
in the stack.

We'll probably need a virtual frame pointer since the offset between the
hard frame pointer and the locals isn't set until after we know how many
saved registers are needed.  But that's known technology.

In general, it seems like a pretty reasonable idea to me.


jeff




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