From: Randolph Chung <randolph@tausq.org>
To: gdb-patches@sources.redhat.com
Subject: Re: [patch/rfa] allow unwinding "past main" for dummy frames
Date: Wed, 08 Dec 2004 03:27:00 -0000 [thread overview]
Message-ID: <20041208015532.GH6359@tausq.org> (raw)
In-Reply-To: <20041206144326.GB14232@nevyn.them.org>
> Patch is OK, but definitely needs a comment. And the comment should
> mention HP/UX specifically.
i've checked this in:
2004-12-07 Randolph Chung <tausq@debian.org>
* frame.c (get_prev_frame): Don't terminate unwinding at main if we
are unwinding through a dummy frame.
Index: frame.c
===================================================================
RCS file: /cvs/src/src/gdb/frame.c,v
retrieving revision 1.195
diff -u -p -r1.195 frame.c
--- frame.c 10 Nov 2004 23:26:33 -0000 1.195
+++ frame.c 8 Dec 2004 01:54:47 -0000
@@ -1199,7 +1199,18 @@ get_prev_frame (struct frame_info *this_
get_current_frame(). */
gdb_assert (this_frame != NULL);
+ /* tausq/2004-12-07: Dummy frames are skipped because it doesn't make much
+ sense to stop unwinding at a dummy frame. One place where a dummy
+ frame may have an address "inside_main_func" is on HPUX. On HPUX, the
+ pcsqh register (space register for the instruction at the head of the
+ instruction queue) cannot be written directly; the only way to set it
+ is to branch to code that is in the target space. In order to implement
+ frame dummies on HPUX, the called function is made to jump back to where
+ the inferior was when the user function was called. If gdb was inside
+ the main function when we created the dummy frame, the dummy frame will
+ point inside the main function. */
if (this_frame->level >= 0
+ && get_frame_type (this_frame) != DUMMY_FRAME
&& !backtrace_past_main
&& inside_main_func (this_frame))
/* Don't unwind past main(). Note, this is done _before_ the
--
Randolph Chung
Debian GNU/Linux Developer, hppa/ia64 ports
http://www.tausq.org/
next prev parent reply other threads:[~2004-12-08 1:55 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-12-06 3:31 Randolph Chung
2004-12-06 3:45 ` Daniel Jacobowitz
2004-12-06 4:27 ` Randolph Chung
2004-12-06 4:59 ` Daniel Jacobowitz
2004-12-06 6:22 ` Randolph Chung
2004-12-06 15:35 ` Daniel Jacobowitz
2004-12-06 16:54 ` Randolph Chung
2004-12-08 3:27 ` Randolph Chung [this message]
2004-12-06 14:11 ` Randolph Chung
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=20041208015532.GH6359@tausq.org \
--to=randolph@tausq.org \
--cc=gdb-patches@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