From: Ulrich Weigand Date: Sat, 9 Jun 2007 14:02:39 +0000 (+0000) Subject: 2007-06-09 Markus Deuling X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=8da95a3048cad9615e407674f8da4e997eb8752f;p=binutils-gdb.git 2007-06-09 Markus Deuling * gdbarch.sh (MEMORY_INSERT_BREAKPOINT): Replace by gdbarch_memory_insert_breakpoint. * mem-break.c (memory_insert_breakpoint): Likewise. * gdbarch.sh (MEMORY_REMOVE_BREAKPOINT): Replace by gdbarch_memory_remove_breakpoint. * mem-break.c (memory_remove_breakpoint): Likewise. * gdbarch.c, gdbarch.h: Regenerate. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index ace7a6523d7..564a07a9350 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,13 @@ +2007-06-09 Markus Deuling + + * gdbarch.sh (MEMORY_INSERT_BREAKPOINT): Replace by + gdbarch_memory_insert_breakpoint. + * mem-break.c (memory_insert_breakpoint): Likewise. + * gdbarch.sh (MEMORY_REMOVE_BREAKPOINT): Replace by + gdbarch_memory_remove_breakpoint. + * mem-break.c (memory_remove_breakpoint): Likewise. + * gdbarch.c, gdbarch.h: Regenerate. + 2007-06-09 Markus Deuling * gdbarch.sh (FETCH_TLS_LOAD_MODULE_ADDRESS): Replace by diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c index a935becab7a..ef92a7e31d0 100644 --- a/gdb/gdbarch.c +++ b/gdb/gdbarch.c @@ -1029,21 +1029,9 @@ gdbarch_dump (struct gdbarch *current_gdbarch, struct ui_file *file) fprintf_unfiltered (file, "gdbarch_dump: long_long_bit = %s\n", paddr_d (current_gdbarch->long_long_bit)); -#ifdef MEMORY_INSERT_BREAKPOINT - fprintf_unfiltered (file, - "gdbarch_dump: %s # %s\n", - "MEMORY_INSERT_BREAKPOINT(bp_tgt)", - XSTRING (MEMORY_INSERT_BREAKPOINT (bp_tgt))); -#endif fprintf_unfiltered (file, "gdbarch_dump: memory_insert_breakpoint = <0x%lx>\n", (long) current_gdbarch->memory_insert_breakpoint); -#ifdef MEMORY_REMOVE_BREAKPOINT - fprintf_unfiltered (file, - "gdbarch_dump: %s # %s\n", - "MEMORY_REMOVE_BREAKPOINT(bp_tgt)", - XSTRING (MEMORY_REMOVE_BREAKPOINT (bp_tgt))); -#endif fprintf_unfiltered (file, "gdbarch_dump: memory_remove_breakpoint = <0x%lx>\n", (long) current_gdbarch->memory_remove_breakpoint); diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h index c1e9d6e0225..18e92f87067 100644 --- a/gdb/gdbarch.h +++ b/gdb/gdbarch.h @@ -699,22 +699,10 @@ extern void set_gdbarch_adjust_breakpoint_address (struct gdbarch *gdbarch, gdba typedef int (gdbarch_memory_insert_breakpoint_ftype) (struct bp_target_info *bp_tgt); extern int gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt); extern void set_gdbarch_memory_insert_breakpoint (struct gdbarch *gdbarch, gdbarch_memory_insert_breakpoint_ftype *memory_insert_breakpoint); -#if !defined (GDB_TM_FILE) && defined (MEMORY_INSERT_BREAKPOINT) -#error "Non multi-arch definition of MEMORY_INSERT_BREAKPOINT" -#endif -#if !defined (MEMORY_INSERT_BREAKPOINT) -#define MEMORY_INSERT_BREAKPOINT(bp_tgt) (gdbarch_memory_insert_breakpoint (current_gdbarch, bp_tgt)) -#endif typedef int (gdbarch_memory_remove_breakpoint_ftype) (struct bp_target_info *bp_tgt); extern int gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, struct bp_target_info *bp_tgt); extern void set_gdbarch_memory_remove_breakpoint (struct gdbarch *gdbarch, gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint); -#if !defined (GDB_TM_FILE) && defined (MEMORY_REMOVE_BREAKPOINT) -#error "Non multi-arch definition of MEMORY_REMOVE_BREAKPOINT" -#endif -#if !defined (MEMORY_REMOVE_BREAKPOINT) -#define MEMORY_REMOVE_BREAKPOINT(bp_tgt) (gdbarch_memory_remove_breakpoint (current_gdbarch, bp_tgt)) -#endif extern CORE_ADDR gdbarch_decr_pc_after_break (struct gdbarch *gdbarch); extern void set_gdbarch_decr_pc_after_break (struct gdbarch *gdbarch, CORE_ADDR decr_pc_after_break); diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh index 91043ca1cec..1fc3f23e376 100755 --- a/gdb/gdbarch.sh +++ b/gdb/gdbarch.sh @@ -545,8 +545,8 @@ f:=:CORE_ADDR:skip_prologue:CORE_ADDR ip:ip:0:0 f::int:inner_than:CORE_ADDR lhs, CORE_ADDR rhs:lhs, rhs:0:0 f:=:const gdb_byte *:breakpoint_from_pc:CORE_ADDR *pcptr, int *lenptr:pcptr, lenptr::0: M::CORE_ADDR:adjust_breakpoint_address:CORE_ADDR bpaddr:bpaddr -f:=:int:memory_insert_breakpoint:struct bp_target_info *bp_tgt:bp_tgt:0:default_memory_insert_breakpoint::0 -f:=:int:memory_remove_breakpoint:struct bp_target_info *bp_tgt:bp_tgt:0:default_memory_remove_breakpoint::0 +f::int:memory_insert_breakpoint:struct bp_target_info *bp_tgt:bp_tgt:0:default_memory_insert_breakpoint::0 +f::int:memory_remove_breakpoint:struct bp_target_info *bp_tgt:bp_tgt:0:default_memory_remove_breakpoint::0 v::CORE_ADDR:decr_pc_after_break:::0:::0 # A function can be addressed by either it's "pointer" (possibly a diff --git a/gdb/mem-break.c b/gdb/mem-break.c index 5a8af0fb771..2122308880f 100644 --- a/gdb/mem-break.c +++ b/gdb/mem-break.c @@ -79,11 +79,11 @@ default_memory_remove_breakpoint (struct bp_target_info *bp_tgt) int memory_insert_breakpoint (struct bp_target_info *bp_tgt) { - return MEMORY_INSERT_BREAKPOINT (bp_tgt); + return gdbarch_memory_insert_breakpoint (current_gdbarch, bp_tgt); } int memory_remove_breakpoint (struct bp_target_info *bp_tgt) { - return MEMORY_REMOVE_BREAKPOINT (bp_tgt); + return gdbarch_memory_remove_breakpoint (current_gdbarch, bp_tgt); }