From: Pedro Alves <palves@redhat.com>
To: Andrew Burgess <andrew.burgess@embecosm.com>, gdb-patches@sourceware.org
Subject: Re: [RFC] Use of create_new_frame from 'frame'.
Date: Wed, 08 Jul 2015 18:02:00 -0000 [thread overview]
Message-ID: <559D659A.50704@redhat.com> (raw)
In-Reply-To: <20150708170944.GA17985@embecosm.com>
On 07/08/2015 06:09 PM, Andrew Burgess wrote:
> The 'frame' command can cause 'create_new_frame' in some conditions:
>
> - When two arguments are passed, or
> - When one argument is passed that is not:
> - A valid index into the backtrace, or
> - A valid stack frame base address.
>
> Personally, I dislike this behaviour because:
>
> 1. It's easy to make a mistake using the frame command and create a
> new frame. It's not obvious (I think) how to recover from this
> situation. [ The answer is just to use 'frame' again with a
> valid frame specifier argument. ]
>
> 2. As a backtrace can be possibly any depth then depending on where
> we stop alters which frames we can create. This seems a little
> arbitrary.
>
Totally agreed. See here for my previous suggestions:
https://sourceware.org/ml/gdb/2014-11/msg00028.html
Related bugs:
https://sourceware.org/bugzilla/show_bug.cgi?id=18074
https://sourceware.org/bugzilla/show_bug.cgi?id=8864
> We could improve #1 by not allowing small indexes that are close to
> the number of frames in the backtrace, however, this feels like a bit
> of a hack, and would be a little annoying on small targets where low
> value addresses are actually valid.
Yeah, yuck. :-)
Thanks,
Pedro Alves
next prev parent reply other threads:[~2015-07-08 18:02 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-08 17:09 Andrew Burgess
2015-07-08 18:02 ` Pedro Alves [this message]
2015-07-08 19:42 ` Eli Zaretskii
2015-07-08 19:46 ` Pedro Alves
2015-07-08 20:06 ` Eli Zaretskii
2015-07-08 20:16 ` Andrew Burgess
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=559D659A.50704@redhat.com \
--to=palves@redhat.com \
--cc=andrew.burgess@embecosm.com \
--cc=gdb-patches@sourceware.org \
/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).