From: Hannes Domani <ssbssa@yahoo.de>
To: Gdb-patches <gdb-patches@sourceware.org>
Subject: Re: [RFC][PATCH 0/6] Step program considering the source column information
Date: Sun, 17 May 2020 00:08:41 +0000 (UTC) [thread overview]
Message-ID: <214896821.2653465.1589674121844@mail.yahoo.com> (raw)
In-Reply-To: <10a0250a-2dc2-891c-aff0-8c9cd8421936@redhat.com>
Am Samstag, 16. Mai 2020, 20:45:30 MESZ hat Pedro Alves <palves@redhat.com> Folgendes geschrieben:
> Hi,
>
> Cool! A few years back, Antoine Tremblay prototyped this
> as well, but it only worked with Clang, because back then
> GCC didn't output column information. I complained about it
> to Jakub Jelinek, who in his usual awesomeness quickly implemented
> GCC support. :-) Quite nice that we're finally getting closer to
> actually making use of it in GDB.
>
> You can still find Antoine's prototype here:
>
> https://github.com/hexa00/binutils-gdb/commits/statement-stepping
I didn't know about that, interesting.
Is there some reason why this wasn't included in gdb back then?
> It would likely be interesting if you could take a look and compare
> approaches. You should be able to borrow any code you find useful, since
> he was working for Ericsson at the time, and had a copyright assignment.
I just checked it out for a bit.
The actual implementation in process_event_stop_test() is a lot simpler,
I will have to try it out and compare the result, maybe that means mine
is unnecessary complicated.
And the calculation of the column indicator position is also more complicated
in mine, but that's because I had to account for the escape sequences of
the syntax highlighting.
> On the name of the new commands -- for a user, thinking in terms
> "step until next column" doesn't make sense IMO. What the user really wants
> is "step until next statement". Column information in the debug
> info enables this, but it's an implementation detail.
> In Antoine's version, he thus had "nexts" instead of "nextc", which
> sounds better to me:
>
> add_com ("nexts", class_run, nexts_command, _("\
> Step program by statement, proceeding through subroutine calls.\n\
> Usage: nexts [N]\n\
> Unlike \"steps\", if the current source line calls a subroutine,\n\
> this command does not enter the subroutine, but instead steps over\n\
> the call, in effect treating it as a single statement."));
> add_com_alias ("ns", "nexts", class_run, 1);
Yes, he has nexts (ns) and steps (ss), I don't really mind either way.
I used nextc/stepc because that was suggested in PR25913.
Hannes
next prev parent reply other threads:[~2020-05-17 0:08 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20200516172632.4803-1-ssbssa.ref@yahoo.de>
2020-05-16 17:26 ` Hannes Domani
2020-05-16 17:26 ` [PATCH 1/6] Add column information of dwarf to the symbol information Hannes Domani
2020-05-18 16:17 ` Tom Tromey
2020-05-19 12:23 ` Luis Machado
2020-05-16 17:26 ` [PATCH 2/6][PR gdb/25913] Implement nextc and stepc commands Hannes Domani
2020-05-16 17:26 ` [PATCH 3/6] Add column information to maint info line-table Hannes Domani
2020-05-16 17:26 ` [PATCH 4/6] Add LineTableEntry.column to python line table interface Hannes Domani
2020-05-27 13:50 ` Tom de Vries
2020-05-27 14:36 ` Tom Tromey
2020-05-16 17:26 ` [PATCH 5/6][PR gdb/25911] Show column of current execution point in frame info Hannes Domani
2020-05-18 16:20 ` Tom Tromey
2020-05-18 16:37 ` Hannes Domani
2020-05-19 14:51 ` Tom Tromey
2020-05-16 17:26 ` [PATCH 6/6] Show column of current execution point in TUI Hannes Domani
2020-05-16 18:45 ` [RFC][PATCH 0/6] Step program considering the source column information Pedro Alves
2020-05-17 0:08 ` Hannes Domani [this message]
2020-05-18 16:21 ` Tom Tromey
2020-05-18 16:28 ` Hannes Domani
2020-05-19 12:27 ` Luis Machado
2020-05-19 16:02 ` Hannes Domani
2020-05-27 15:33 ` Tom de Vries
2020-05-27 16:04 ` Hannes Domani
2020-06-02 9:08 ` Tom de Vries
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=214896821.2653465.1589674121844@mail.yahoo.com \
--to=ssbssa@yahoo.de \
--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