This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [rfa:NetBSD/ppc] Implement signal trampoline unwinder
- From: Kevin Buettner <kevinb at redhat dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: Tue, 2 Mar 2004 15:21:28 -0700
- Subject: Re: [rfa:NetBSD/ppc] Implement signal trampoline unwinder
- Organization: Red Hat
- References: <40428C58.1020506@gnu.org>
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