From: Christophe LYON <christophe.lyon@st.com>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb@sources.redhat.com
Subject: Re: dwarf2 frame unwinder assumptions on SP
Date: Mon, 11 Jul 2005 15:33:00 -0000 [thread overview]
Message-ID: <42D290FF.F665B4A1@st.com> (raw)
In-Reply-To: <20050711145053.GA29229@nevyn.them.org>
> > Currently, in my x-tdep.c I have:
> > set_gdbarch_unwind_pc(gdbarch, x_unwind_pc);
> > frame_unwind_append_sniffer (gdbarch, dwarf2_frame_sniffer);
>
> It sounds like you need to set a "frame base" sniffer also, other than
> the dwarf one. The dwarf2 frame unwinder does not set anything related
> to the "frame base" used by symbolic debug information; it only unwinds
> the stack pointer as best it can.
>
> Does "print $sp" work correctly when unwinding?
>
At frame #0, it's OK, at frame #1 it is not (it displays CFA).
I have tried to add
frame_base_set_default (gdbarch, &x_frame_base);
where
static CORE_ADDR
x_frame_base_address (struct frame_info *next_frame, void **this_cache)
{
struct lx_frame_cache *cache = x_frame_cache (next_frame, this_cache);
fprintf(stderr, "In %s\n", __FUNCTION__);
return cache->base;
}
static const struct frame_base x_frame_base =
{
&x_frame_unwind,
x_frame_base_address,
x_frame_base_address,
x_frame_base_address
};
but in my test case x_frame_base_address() is not called.
(in funcargs, I set a bkp in call6b, run, then backtrace)
Isn't this what you mean by "frame base sniffer" ?
Thanks,
Christophe.
next prev parent reply other threads:[~2005-07-11 15:33 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-11 14:44 Christophe LYON
2005-07-11 14:51 ` Daniel Jacobowitz
2005-07-11 15:33 ` Christophe LYON [this message]
2005-07-11 15:47 ` Daniel Jacobowitz
2005-07-11 15:58 ` Christophe LYON
2005-07-11 16:03 ` Daniel Jacobowitz
2005-07-11 17:02 ` Richard Henderson
2005-07-11 17:06 ` Daniel Jacobowitz
2005-07-11 19:47 ` Mark Kettenis
2005-07-12 14:05 ` Christophe LYON
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=42D290FF.F665B4A1@st.com \
--to=christophe.lyon@st.com \
--cc=drow@false.org \
--cc=gdb@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).