From: Andrew Cagney <cagney@gnu.org>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [rfa/mips] Stop backtraces when we've lost the PC
Date: Mon, 08 Mar 2004 00:56:00 -0000 [thread overview]
Message-ID: <404BC4B2.7000100@gnu.org> (raw)
In-Reply-To: <20040306231743.GA9379@nevyn.them.org>
> Here's an updated version of a little hack I've been using since GDB 6.0.
> If we are in a nested normal frame, i.e. something whose next frame is a
> function that it called in the normal way, and we didn't find a saved PC,
> we're going to be stuck in a loop. We might have been able to figure out
> the frame size, but not where the return address was stored; as the comment
> says, this happens in glibc's clone function. Of course the problem there
> is that it _doesn't_ save $ra in the normal fashion; it won't return.
>
> Without this patch schedlock.exp falls apart, because backtraces continue
> forever printing "clone()" on every line.
>
> OK?
No!
> + if (frame_relative_level (next_frame) >= 0
> + && get_frame_type (next_frame) == NORMAL_FRAME
> + && !trad_frame_addr_p (info->saved_regs, NUM_REGS + PC_REGNUM))
The whole point of this recursive code is that you don't need to add
hacks that look down the stack at the type of more inner frames :-/
Can you post the relevant assembler so that we can determine why the
prologue analyzer is failing.
Andrew
WARNING: multiple messages have this Message-ID
From: Andrew Cagney <cagney@gnu.org>
To: Daniel Jacobowitz <drow@false.org>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [rfa/mips] Stop backtraces when we've lost the PC
Date: Fri, 19 Mar 2004 00:09:00 -0000 [thread overview]
Message-ID: <404BC4B2.7000100@gnu.org> (raw)
Message-ID: <20040319000900.E8VgPtdel3L57s_7pSw7oP1OBxSgpt4HVwyrI1dUSN0@z> (raw)
In-Reply-To: <20040306231743.GA9379@nevyn.them.org>
> Here's an updated version of a little hack I've been using since GDB 6.0.
> If we are in a nested normal frame, i.e. something whose next frame is a
> function that it called in the normal way, and we didn't find a saved PC,
> we're going to be stuck in a loop. We might have been able to figure out
> the frame size, but not where the return address was stored; as the comment
> says, this happens in glibc's clone function. Of course the problem there
> is that it _doesn't_ save $ra in the normal fashion; it won't return.
>
> Without this patch schedlock.exp falls apart, because backtraces continue
> forever printing "clone()" on every line.
>
> OK?
No!
> + if (frame_relative_level (next_frame) >= 0
> + && get_frame_type (next_frame) == NORMAL_FRAME
> + && !trad_frame_addr_p (info->saved_regs, NUM_REGS + PC_REGNUM))
The whole point of this recursive code is that you don't need to add
hacks that look down the stack at the type of more inner frames :-/
Can you post the relevant assembler so that we can determine why the
prologue analyzer is failing.
Andrew
next prev parent reply other threads:[~2004-03-08 0:56 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-19 0:09 Daniel Jacobowitz
2004-03-06 23:17 ` Daniel Jacobowitz
2004-03-08 0:56 ` Andrew Cagney [this message]
2004-03-08 3:23 ` Daniel Jacobowitz
2004-03-19 0:09 ` Andrew Cagney
2004-03-08 16:33 ` Andrew Cagney
2004-03-19 0:09 ` Daniel Jacobowitz
2004-03-08 15:48 ` Daniel Jacobowitz
2004-03-08 20:26 ` Daniel Jacobowitz
2004-03-19 0:09 ` Andrew Cagney
2004-03-17 22:11 ` Andrew Cagney
2004-03-22 21:07 ` Daniel Jacobowitz
2004-03-19 0:09 ` Daniel Jacobowitz
2004-03-11 20:51 ` Andrew Cagney
2004-03-19 0:09 ` Daniel Jacobowitz
2004-03-11 20:57 ` Daniel Jacobowitz
2004-03-19 0:09 ` Andrew Cagney
2004-03-11 23:47 ` Andrew Cagney
2004-03-19 0:09 ` Daniel Jacobowitz
2004-03-12 0:00 ` Daniel Jacobowitz
2004-03-19 0:09 ` Andrew Cagney
2004-03-19 0:09 ` Daniel Jacobowitz
2004-03-08 17:41 ` Daniel Jacobowitz
2004-03-19 0:09 ` Daniel Jacobowitz
2004-03-19 0:09 ` Andrew Cagney
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=404BC4B2.7000100@gnu.org \
--to=cagney@gnu.org \
--cc=drow@false.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