From: Pedro Alves <palves@redhat.com>
To: gdb-patches@sourceware.org
Subject: [PATCH v3 0/5] Fix lost events, and handle multiple step-overs.
Date: Fri, 07 Mar 2014 01:10:00 -0000 [thread overview]
Message-ID: <1394154640-14053-1-git-send-email-palves@redhat.com> (raw)
Here's v3. This version mainly addresses Doug's review of patch 2 of
v2. As the rest of the series would no longer apply and one patch
needed a minor corresponding tweak, I'm resending it all.
v2 was here:
https://sourceware.org/ml/gdb-patches/2014-03/msg00128.html
v1 was here:
https://sourceware.org/ml/gdb-patches/2014-02/msg00761.html.
What remains is related to GDB losing events - breakpoints and
watchpoints - in some situations, about teaching GDB that it might
need to step over breakpoints in multiple threads.
One nice side effect of patch #2 is that GDB no longer removes/inserts
_all_ breakpoints when stepping over one. GDB after that only removes
the breakpoint being stepped over. This eliminates a lot of z0/Z0 RSP
traffic if you have a lot of breakpoints, and have a conditional or
thread-specific breakpoint constantly triggering and not causing a
user-visible stop.
This changes heavily core run control code, which affects software
single-step targets too. For more comfortable development and
testing, I actually hacked on this against my software single-step on
x86 branch first.
Tested on x86_64 Fedora 17, against pristine mainline, and against a
series that implements software single-step on x86-64.
For convenience, you can find this series at:
git@github.com:palves/gdb.git fix_a_bunch_of_run_control_bugs_v3
and with software single-step on x86 on top:
git@github.com:palves/gdb.git fix_a_bunch_of_run_control_bugs_v3_sss
In absence of barring comments, I plan to push this in soon.
Changes in v3:
- Polish patch for PR breakpoints/7143, in response to Doug's review.
Changes in v2:
- Two patches of v1 applied.
- Order of some of the remaining patches changed.
- Bugs that exposed were fixed.
- One test moved to a different patch and got extended to cover
another scenario gdb was mishandling and this series fixes.
- Yao's review comments to v1's tests (to date) are addressed.
- Software single-step breakpoints are not longer converted to real
breakpoints.
Pedro Alves (5):
Fix missing breakpoint/watchpoint hits, eliminate deferred_step_ptid.
PR breakpoints/7143 - Watchpoint does not trigger when first set
Fix for even more missed events; eliminate thread-hop code.
Handle multiple step-overs.
Make signal-while-stepping-over-bp-other-thread.exp run against
remote targets too.
gdb/breakpoint.c | 25 +-
gdb/breakpoint.h | 13 +
gdb/inferior.h | 6 +
gdb/infrun.c | 765 ++++++++++-----------
gdb/testsuite/gdb.base/watchpoint.exp | 13 +-
gdb/testsuite/gdb.cp/annota2.exp | 3 -
gdb/testsuite/gdb.cp/annota3.exp | 3 -
gdb/testsuite/gdb.threads/multiple-step-overs.c | 105 +++
gdb/testsuite/gdb.threads/multiple-step-overs.exp | 80 +++
.../signal-while-stepping-over-bp-other-thread.c | 2 +
.../signal-while-stepping-over-bp-other-thread.exp | 16 +-
.../gdb.threads/step-over-lands-on-breakpoint.c | 65 ++
.../gdb.threads/step-over-lands-on-breakpoint.exp | 62 ++
.../gdb.threads/step-over-trips-on-watchpoint.c | 67 ++
.../gdb.threads/step-over-trips-on-watchpoint.exp | 90 +++
15 files changed, 877 insertions(+), 438 deletions(-)
create mode 100644 gdb/testsuite/gdb.threads/multiple-step-overs.c
create mode 100644 gdb/testsuite/gdb.threads/multiple-step-overs.exp
create mode 100644 gdb/testsuite/gdb.threads/step-over-lands-on-breakpoint.c
create mode 100644 gdb/testsuite/gdb.threads/step-over-lands-on-breakpoint.exp
create mode 100644 gdb/testsuite/gdb.threads/step-over-trips-on-watchpoint.c
create mode 100644 gdb/testsuite/gdb.threads/step-over-trips-on-watchpoint.exp
--
1.7.11.7
next reply other threads:[~2014-03-07 1:10 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-07 1:10 Pedro Alves [this message]
2014-03-07 1:10 ` [PATCH v3 2/5] PR breakpoints/7143 - Watchpoint does not trigger when first set Pedro Alves
2014-03-16 3:41 ` Doug Evans
2014-03-17 17:11 ` Pedro Alves
2014-03-19 16:52 ` Doug Evans
2014-03-20 13:58 ` Pedro Alves
2014-03-20 13:57 ` Pedro Alves
2014-06-17 19:18 ` Regression for watchpoint-fork.exp [Re: [PATCH v3 2/5] PR breakpoints/7143 - Watchpoint does not trigger when first set] Jan Kratochvil
2014-06-18 10:43 ` Pedro Alves
2014-06-19 13:43 ` Jan Kratochvil
2014-06-19 15:02 ` Pedro Alves
2014-06-19 16:56 ` Pedro Alves
2014-06-19 17:00 ` Jan Kratochvil
2014-06-20 16:53 ` [PATCH] x86 Linux watchpoints: Couldn't write debug register: Invalid, argument Pedro Alves
2014-06-20 17:45 ` Tom Tromey
2014-06-20 17:52 ` Pedro Alves
2014-06-20 17:53 ` Tom Tromey
2014-06-22 18:31 ` Jan Kratochvil
2014-06-23 17:41 ` Pedro Alves
2014-06-23 17:44 ` Pedro Alves
2014-03-07 1:10 ` [PATCH v3 4/5] Handle multiple step-overs Pedro Alves
2014-03-07 1:10 ` [PATCH v3 1/5] Fix missing breakpoint/watchpoint hits, eliminate deferred_step_ptid Pedro Alves
2014-03-07 1:10 ` [PATCH v3 3/5] Fix for even more missed events; eliminate thread-hop code Pedro Alves
2014-03-07 1:10 ` [PATCH v3 5/5] Make signal-while-stepping-over-bp-other-thread.exp run against remote targets too Pedro Alves
2014-03-20 13:59 ` [PUSHED] Re: [PATCH v3 0/5] Fix lost events, and handle multiple step-overs Pedro Alves
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=1394154640-14053-1-git-send-email-palves@redhat.com \
--to=palves@redhat.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).