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]
Other format: [Raw text]

Re: RFA (Was: Re: RFC / RFA): dwarf2 unwinding for targets withcall-part-clobbered


On Wed, 2003-07-09 at 05:10, Joern Rennecke wrote:
> expand_builtin_init_dwarf_reg_sizes means that extra data is clobbered
> on little endian, and for big endian, the restored values are completely
> garbled.

Since expand_builtin_init_dwarf_ref_sizes is in dwarf2out.c, I would
expect that it would somehow use dwarf info to determine the sizes of
the registers to restore.  However, it isn't clear how to do that, so
your choose_hard_reg_mode suggestion seems reasoanble.

> > > So the only clean way to do this is to add another parameter to
> > > choose_hard_reg_mode that makes it return the largest mode that is not
> > > partially clobbered.

I don't see why you need the wide_mode stuff in choose_hard_reg_mode. 
It seems like an unnecessary complication.  I would expect that for all
targets that use HARD_REGNO_CALL_PART_CLOBBERED, they would accept the
same size regardless of mode class, so we only need to return the first
one we find that isn't VOIDmode.

This is no different than how the current code behaves.  If you define a
register that accepts different max sizes of int and float, then
reg_raw_mode will return the max int size, regardless of whether this is
bigger than the max float size.  Obviously, we don't handle that case,
so we don't need to worry about it when HARD_REGNO_CALL_PART_CLOBBER is
defined either.

Jim



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