aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog7
-rw-r--r--gdb/arm-linux-tdep.c5
-rw-r--r--gdb/arm-tdep.c5
3 files changed, 15 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 163e1a9..3e6bd4c 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,12 @@
2016-11-08 Yao Qi <yao.qi@linaro.org>
+ * arm-linux-tdep.c (arm_linux_software_single_step): Write
+ adjusted address back to vector. Call insert_single_step_breakpoint
+ in a new loop.
+ * arm-tdep.c (arm_software_single_step): Likewise.
+
+2016-11-08 Yao Qi <yao.qi@linaro.org>
+
* arm-linux-tdep.c (arm_linux_software_single_step): Don't
call arm_insert_single_step_breakpoint, call
insert_single_step_breakpoint instead.
diff --git a/gdb/arm-linux-tdep.c b/gdb/arm-linux-tdep.c
index bc92177..4a734b0 100644
--- a/gdb/arm-linux-tdep.c
+++ b/gdb/arm-linux-tdep.c
@@ -952,9 +952,12 @@ arm_linux_software_single_step (struct frame_info *frame)
for (i = 0; VEC_iterate (CORE_ADDR, next_pcs, i, pc); i++)
{
pc = gdbarch_addr_bits_remove (gdbarch, pc);
- insert_single_step_breakpoint (gdbarch, aspace, pc);
+ VEC_replace (CORE_ADDR, next_pcs, i, pc);
}
+ for (i = 0; VEC_iterate (CORE_ADDR, next_pcs, i, pc); i++)
+ insert_single_step_breakpoint (gdbarch, aspace, pc);
+
do_cleanups (old_chain);
return 1;
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index a3bea97..9340b3b 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -6310,9 +6310,12 @@ arm_software_single_step (struct frame_info *frame)
for (i = 0; VEC_iterate (CORE_ADDR, next_pcs, i, pc); i++)
{
pc = gdbarch_addr_bits_remove (gdbarch, pc);
- insert_single_step_breakpoint (gdbarch, aspace, pc);
+ VEC_replace (CORE_ADDR, next_pcs, i, pc);
}
+ for (i = 0; VEC_iterate (CORE_ADDR, next_pcs, i, pc); i++)
+ insert_single_step_breakpoint (gdbarch, aspace, pc);
+
do_cleanups (old_chain);
return 1;