This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB 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:NetBSD/ppc] Implement signal trampoline unwinder


On Sun, 29 Feb 2004 20:05:28 -0500
Andrew Cagney <cagney@gnu.org> wrote:

>	* ppcnbsd-tdep.c: Include "trad-frame.h", and "frame-unwind.h".
>	(struct ppcnbsd_sigtramp_cache, ppcnbsd_sigtramp_this_id)
>	(ppcnbsd_sigtramp_prev_register, ppcnbsd_sigtramp_cache)
>	(ppcnbsd_sigtramp_sniffer, ppcnbsd_sigtramp_unwind)
>	(ppcnbsd_init_abi): Implement a NetBSD/PPC signal trampline
>	unwinder, register.

After reading the disucssion, the only part about this which bothers
me is the part that you yourself had a question about:

> +  if (frame_pc_unwind (next_frame) > 0x7f000000)
> +    /* Assume anything that is vaguely on the stack is a signal
> +       trampoline.  */
> +    return &ppcnbsd_sigtramp_unwind;

Given Mark K's comments, I think it would be better to check for a
specific instruction sequence.  I know it's expensive, but it seems
like a more robust approach.  (But, also given Mark K's comments,
it seems that a name based approach will work well in the future.)

Kevin


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