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: [Patch] MIPS: Fix unwinding through signal frames for n32 and n64 ABIs.

David Daney <> writes:
> As noted by Daniel Jacobowitz, this patch:
> broke unwinding through signal frames on n32 and n64 ABIs.  It also 
> causes 4.3 to emit aliasing warnings.
> My new patch fixes both of these problems.
> The root of the problem is that the original MD_FALLBACK_FRAME_STATE_FOR 
> support for MIPS placed the return address in the register slot use by 
> $hi.  This register has the same width as the other general purpose 
> registers.  This was causing the unwinder to assert because the width of 
> the return address (Pmode) differs from that of the registers in the n32 
> ABI (32 bits vs. 64).
> The fix is to move the SIGNAL_UNWIND_RETURN_COLUMN into an unused column 
> and give that column the with of Pmode.

I wonder if it would be better to define DWARF_ALT_FRAME_RETURN_COLUMN
to the new register?  You then wouldn't need to bother with
HARD_REGNO_MODE_OK, etc., which I think is a good thing: this
register is a purely DWARF concept, it isn't a gcc register.

Either way, the change is going to extend the ABI -- DWARF register 66
should not be used for other purposes going forward -- and I think
defining DWARF_ALT_FRAME_RETURN_COLUMN makes that a little more

(It's probably a good idea to keep SIGNAL_UNWIND_RETURN_COLUMN too,


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