diff options
author | Pedro Alves <palves@redhat.com> | 2015-02-23 18:59:38 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2015-02-23 18:59:38 +0000 |
commit | 8090aef2bf5021f35c94193a035eb1ecd5e25e41 (patch) | |
tree | 44fb568a423a98e87a8e2573c81c29e29865f90a /gdb/compile | |
parent | d8b901edd1a9b717bd397400ce498c7a2d9504d0 (diff) | |
download | binutils-8090aef2bf5021f35c94193a035eb1ecd5e25e41.zip binutils-8090aef2bf5021f35c94193a035eb1ecd5e25e41.tar.gz binutils-8090aef2bf5021f35c94193a035eb1ecd5e25e41.tar.bz2 |
gdbserver: redo stepping over breakpoint that was on top of a permanent breakpoint
I'm going to add an alternate mechanism of breakpoint trap
identification to 'check_stopped_by_breakpoint' that does not rely on
checking the instruction at PC. The mechanism currently used to tell
whether we're stepping over a permanent breakpoint doesn't fit in that
new method. This patch redoes the whole logic in a different way that
works with both old and new methods, in essence moving the "stepped
permanent breakpoint" detection "one level up". It makes lower level
check_stopped_by_breakpoint always the adjust the PC, and then has
linux_wait_1 advance the PC past the breakpoint if necessary. This
ends up being better also because this now handles
non-decr_pc_after_break targets too. Before, such targets would get
stuck forever reexecuting the breakpoint instruction.
Tested on x86_64 Fedora 20.
gdb/gdbserver/ChangeLog:
2015-02-23 Pedro Alves <palves@redhat.com>
* linux-low.c (check_stopped_by_breakpoint): Don't check if the
thread was doing a step-over; always adjust the PC if
we stepped over a permanent breakpoint.
(linux_wait_1): If we stepped over breakpoint that was on top of a
permanent breakpoint, manually advance the PC past it.
Diffstat (limited to 'gdb/compile')
0 files changed, 0 insertions, 0 deletions