From: Eli Zaretskii <eliz@gnu.org>
To: Stan Shebs <stan@codesourcery.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH] Infer $pc in a file's trace frame
Date: Fri, 02 Apr 2010 07:05:00 -0000 [thread overview]
Message-ID: <83tyruwd0a.fsf@gnu.org> (raw)
In-Reply-To: <4BB51AFC.1010303@codesourcery.com>
> Date: Thu, 01 Apr 2010 15:15:24 -0700
> From: Stan Shebs <stan@codesourcery.com>
>
> This patch is a small usability enhancement from trace frames coming
> from a trace file; if registers have not been collected, then clear them
> all, and guess that $pc must be the same as the tracepoint's address.
> This isn't a good idea for either multi-location tracepoints or stepping
> frames though, and we want to warn the user about those cases.
Thanks.
> + @item
> + If you do not collect registers at a tracepoint, @value{GDBN} can
> + infer that the value of the PC is the address of the tracepoint and
> + display that when you are looking at a trace frame for that
> + tracepoint. However, this cannot work if the tracepoint has multiple
> + locations (for instance if it was set in a function that was inlined),
> + or if it has a @code{while-stepping} loop. In those cases
> + @value{GDBN} will warn you that it can't infer the PC, and default it
> + to zero. Also, @code{tdump} will use the list of collections for the
> + tracepoint proper, and not its stepping list, although the values
> + displayed will be correct for the stepping frame. Explicit print
> + commands will always work correctly.
This is okay, but the last two sentences leave so much stuff
unexplained that I doubt the reader will be able to understand their
meaning, unless she is a tracepoint hacker. At the very least, I
think you should:
. add cross-references to where `tdump' and `while-stepping' are
described
. use the same terminology as you do there, and if the terminology
is not explained there ("stepping list"? what's that?), introduce
it in those places
. add an example to show the issues you are describing.
Btw, the description of `tdump' has nothing to say about any special
behavior in the presence of `while-stepping', whereas the above seems
to hint that there's something we should say about that.
next prev parent reply other threads:[~2010-04-02 7:05 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-01 22:15 Stan Shebs
2010-04-02 7:05 ` Eli Zaretskii [this message]
2010-04-04 23:25 ` Stan Shebs
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=83tyruwd0a.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=gdb-patches@sourceware.org \
--cc=stan@codesourcery.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