aboutsummaryrefslogtreecommitdiff
path: root/gdb/arch-utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/arch-utils.c')
-rw-r--r--gdb/arch-utils.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/gdb/arch-utils.c b/gdb/arch-utils.c
index 41cf828..a2e76de 100644
--- a/gdb/arch-utils.c
+++ b/gdb/arch-utils.c
@@ -826,7 +826,18 @@ int default_insn_is_jump (struct gdbarch *gdbarch, CORE_ADDR addr)
return 0;
}
-/* */
+void
+default_skip_permanent_breakpoint (struct regcache *regcache)
+{
+ struct gdbarch *gdbarch = get_regcache_arch (regcache);
+ CORE_ADDR current_pc = regcache_read_pc (regcache);
+ const gdb_byte *bp_insn;
+ int bp_len;
+
+ bp_insn = gdbarch_breakpoint_from_pc (gdbarch, &current_pc, &bp_len);
+ current_pc += bp_len;
+ regcache_write_pc (regcache, current_pc);
+}
/* -Wmissing-prototypes */
extern initialize_file_ftype _initialize_gdbarch_utils;