diff options
author | Michael Snyder <msnyder@specifix.com> | 2008-09-17 18:17:23 +0000 |
---|---|---|
committer | Michael Snyder <msnyder@specifix.com> | 2008-09-17 18:17:23 +0000 |
commit | df4f7b77c4c9c1989df13b7e6ab310092d5d2235 (patch) | |
tree | a26f2040434157e482be59f2d4d44ff501046e96 | |
parent | c1c0ccaa2e96867c9499b3020dd9101367025f4a (diff) | |
download | gdb-df4f7b77c4c9c1989df13b7e6ab310092d5d2235.tar.gz |
2008-09-15 Michael Snyder <msnyder@vmware.com>
* infrun.c (proceed): No need to singlestep over a breakpoint
when resuming in reverse.
-rw-r--r-- | gdb/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/infrun.c | 10 |
2 files changed, 13 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 78f21acb93e..9dd4d9118ec 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2008-09-15 Michael Snyder <msnyder@vmware.com> + + * infrun.c (proceed): No need to singlestep over a breakpoint + when resuming in reverse. + 2008-09-11 Hui Zhu <teawater@gmail.com> * record.c (record_resume): Change diff --git a/gdb/infrun.c b/gdb/infrun.c index abc600a31fa..dff4996d74e 100644 --- a/gdb/infrun.c +++ b/gdb/infrun.c @@ -1226,11 +1226,17 @@ proceed (CORE_ADDR addr, enum target_signal siggnal, int step) if (addr == (CORE_ADDR) -1) { - if (pc == stop_pc && breakpoint_here_p (pc)) + if (pc == stop_pc && breakpoint_here_p (pc) + && target_get_execution_direction () != EXEC_REVERSE) /* There is a breakpoint at the address we will resume at, step one instruction before inserting breakpoints so that we do not stop right away (and report a second hit at this - breakpoint). */ + breakpoint). + + Note, we don't do this in reverse, because we won't + actually be executing the breakpoint insn anyway. + We'll be (un-)executing the previous instruction. */ + oneproc = 1; else if (gdbarch_single_step_through_delay_p (gdbarch) && gdbarch_single_step_through_delay (gdbarch, |