From: Ulrich Weigand Date: Fri, 11 May 2007 19:16:04 +0000 (+0000) Subject: * gdbarch.sh (remote_translate_xfer_address): Remove. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=93ce7684566b4347cf4135f828dcffdb48417ebb;p=binutils-gdb.git * gdbarch.sh (remote_translate_xfer_address): Remove. * gdbarch.h, gdbarch.c: Regenerate. * arch-utils.c (generic_remote_translate_xfer_address): Remove. * arch-utils.h (generic_remote_translate_xfer_address): Remove. * remote.c (remote_write_bytes_aux, remote_read_bytes): Do not call gdbarch_remote_translate_xfer_address. * frv-tdep.c (frv_gdbarch_init): Do not call set_gdbarch_remote_translate_xfer_address. * ia64-tdep.c (ia64_remote_translate_xfer_address): Remove. (ia64_gdbarch_init): Do not install it. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index a1768dba87f..28a42cbdbf9 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,16 @@ +2007-05-11 Ulrich Weigand + + * gdbarch.sh (remote_translate_xfer_address): Remove. + * gdbarch.h, gdbarch.c: Regenerate. + * arch-utils.c (generic_remote_translate_xfer_address): Remove. + * arch-utils.h (generic_remote_translate_xfer_address): Remove. + * remote.c (remote_write_bytes_aux, remote_read_bytes): Do not + call gdbarch_remote_translate_xfer_address. + * frv-tdep.c (frv_gdbarch_init): Do not call + set_gdbarch_remote_translate_xfer_address. + * ia64-tdep.c (ia64_remote_translate_xfer_address): Remove. + (ia64_gdbarch_init): Do not install it. + 2007-05-11 Bob Wilson * NEWS: Mention change in handling the -tui option. diff --git a/gdb/arch-utils.c b/gdb/arch-utils.c index 7b32b066bfd..1f85b38d294 100644 --- a/gdb/arch-utils.c +++ b/gdb/arch-utils.c @@ -119,16 +119,6 @@ generic_in_function_epilogue_p (struct gdbarch *gdbarch, CORE_ADDR pc) return 0; } -void -generic_remote_translate_xfer_address (struct gdbarch *gdbarch, - struct regcache *regcache, - CORE_ADDR gdb_addr, int gdb_len, - CORE_ADDR * rem_addr, int *rem_len) -{ - *rem_addr = gdb_addr; - *rem_len = gdb_len; -} - /* Helper functions for INNER_THAN */ int diff --git a/gdb/arch-utils.h b/gdb/arch-utils.h index 1b29a838554..625a37e6c8c 100644 --- a/gdb/arch-utils.h +++ b/gdb/arch-utils.h @@ -45,9 +45,6 @@ enum return_value_convention legacy_return_value (struct gdbarch *gdbarch, address passed as an invisible first argument to the function. */ extern gdbarch_deprecated_use_struct_convention_ftype always_use_struct_convention; -/* Typical remote_translate_xfer_address */ -extern gdbarch_remote_translate_xfer_address_ftype generic_remote_translate_xfer_address; - /* The only possible cases for inner_than. */ extern int core_addr_lessthan (CORE_ADDR lhs, CORE_ADDR rhs); extern int core_addr_greaterthan (CORE_ADDR lhs, CORE_ADDR rhs); diff --git a/gdb/frv-tdep.c b/gdb/frv-tdep.c index 0ced24c9d3e..cdb7882c7f3 100644 --- a/gdb/frv-tdep.c +++ b/gdb/frv-tdep.c @@ -1518,9 +1518,6 @@ frv_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) set_gdbarch_write_pc (gdbarch, generic_target_write_pc); - set_gdbarch_remote_translate_xfer_address - (gdbarch, generic_remote_translate_xfer_address); - /* Hardware watchpoint / breakpoint support. */ switch (info.bfd_arch_info->mach) { diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c index fc70f753e4f..7e8c6972786 100644 --- a/gdb/gdbarch.c +++ b/gdb/gdbarch.c @@ -200,7 +200,6 @@ struct gdbarch gdbarch_memory_remove_breakpoint_ftype *memory_remove_breakpoint; CORE_ADDR decr_pc_after_break; CORE_ADDR deprecated_function_start_offset; - gdbarch_remote_translate_xfer_address_ftype *remote_translate_xfer_address; gdbarch_remote_register_number_ftype *remote_register_number; gdbarch_fetch_tls_load_module_address_ftype *fetch_tls_load_module_address; CORE_ADDR frame_args_skip; @@ -327,7 +326,6 @@ struct gdbarch startup_gdbarch = 0, /* memory_remove_breakpoint */ 0, /* decr_pc_after_break */ 0, /* deprecated_function_start_offset */ - generic_remote_translate_xfer_address, /* remote_translate_xfer_address */ default_remote_register_number, /* remote_register_number */ 0, /* fetch_tls_load_module_address */ 0, /* frame_args_skip */ @@ -438,7 +436,6 @@ gdbarch_alloc (const struct gdbarch_info *info, current_gdbarch->deprecated_use_struct_convention = generic_use_struct_convention; current_gdbarch->memory_insert_breakpoint = default_memory_insert_breakpoint; current_gdbarch->memory_remove_breakpoint = default_memory_remove_breakpoint; - current_gdbarch->remote_translate_xfer_address = generic_remote_translate_xfer_address; current_gdbarch->remote_register_number = default_remote_register_number; current_gdbarch->stabs_argument_has_addr = default_stabs_argument_has_addr; current_gdbarch->convert_from_func_ptr_addr = convert_from_func_ptr_addr_identity; @@ -581,7 +578,6 @@ verify_gdbarch (struct gdbarch *current_gdbarch) /* Skip verify of memory_remove_breakpoint, invalid_p == 0 */ /* Skip verify of decr_pc_after_break, invalid_p == 0 */ /* Skip verify of deprecated_function_start_offset, invalid_p == 0 */ - /* Skip verify of remote_translate_xfer_address, invalid_p == 0 */ /* Skip verify of remote_register_number, invalid_p == 0 */ /* Skip verify of fetch_tls_load_module_address, has predicate */ /* Skip verify of frame_args_skip, invalid_p == 0 */ @@ -1408,9 +1404,6 @@ gdbarch_dump (struct gdbarch *current_gdbarch, struct ui_file *file) fprintf_unfiltered (file, "gdbarch_dump: remote_register_number = <0x%lx>\n", (long) current_gdbarch->remote_register_number); - fprintf_unfiltered (file, - "gdbarch_dump: remote_translate_xfer_address = <0x%lx>\n", - (long) current_gdbarch->remote_translate_xfer_address); fprintf_unfiltered (file, "gdbarch_dump: gdbarch_return_value_p() = %d\n", gdbarch_return_value_p (current_gdbarch)); @@ -2896,23 +2889,6 @@ set_gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarch, gdbarch->deprecated_function_start_offset = deprecated_function_start_offset; } -void -gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len) -{ - gdb_assert (gdbarch != NULL); - gdb_assert (gdbarch->remote_translate_xfer_address != NULL); - if (gdbarch_debug >= 2) - fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_translate_xfer_address called\n"); - gdbarch->remote_translate_xfer_address (gdbarch, regcache, gdb_addr, gdb_len, rem_addr, rem_len); -} - -void -set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, - gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address) -{ - gdbarch->remote_translate_xfer_address = remote_translate_xfer_address; -} - int gdbarch_remote_register_number (struct gdbarch *gdbarch, int regno) { diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h index d555d8f7f7f..a2aa83ae33a 100644 --- a/gdb/gdbarch.h +++ b/gdb/gdbarch.h @@ -883,10 +883,6 @@ extern void set_gdbarch_deprecated_function_start_offset (struct gdbarch *gdbarc #define DEPRECATED_FUNCTION_START_OFFSET (gdbarch_deprecated_function_start_offset (current_gdbarch)) #endif -typedef void (gdbarch_remote_translate_xfer_address_ftype) (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len); -extern void gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len); -extern void set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch, gdbarch_remote_translate_xfer_address_ftype *remote_translate_xfer_address); - /* Return the remote protocol register number associated with this register. Normally the identity mapping. */ diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh index 5ead5316ec8..349e181f0e7 100755 --- a/gdb/gdbarch.sh +++ b/gdb/gdbarch.sh @@ -561,8 +561,6 @@ v:=:CORE_ADDR:decr_pc_after_break:::0:::0 v:=:CORE_ADDR:deprecated_function_start_offset:::0:::0 -m::void:remote_translate_xfer_address:struct regcache *regcache, CORE_ADDR gdb_addr, int gdb_len, CORE_ADDR *rem_addr, int *rem_len:regcache, gdb_addr, gdb_len, rem_addr, rem_len::generic_remote_translate_xfer_address::0 - # Return the remote protocol register number associated with this # register. Normally the identity mapping. m::int:remote_register_number:int regno:regno::default_remote_register_number::0 diff --git a/gdb/ia64-tdep.c b/gdb/ia64-tdep.c index a4ddfff536c..a8af64b1aed 100644 --- a/gdb/ia64-tdep.c +++ b/gdb/ia64-tdep.c @@ -3546,16 +3546,6 @@ ia64_store_return_value (struct type *type, struct regcache *regcache, regcache_cooked_write (regcache, IA64_GR8_REGNUM, valbuf); } -static void -ia64_remote_translate_xfer_address (struct gdbarch *gdbarch, - struct regcache *regcache, - CORE_ADDR memaddr, int nr_bytes, - CORE_ADDR *targ_addr, int *targ_len) -{ - *targ_addr = memaddr; - *targ_len = nr_bytes; -} - static int ia64_print_insn (bfd_vma memaddr, struct disassemble_info *info) { @@ -3657,9 +3647,6 @@ ia64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) /* Settings that should be unnecessary. */ set_gdbarch_inner_than (gdbarch, core_addr_lessthan); - set_gdbarch_remote_translate_xfer_address ( - gdbarch, ia64_remote_translate_xfer_address); - set_gdbarch_print_insn (gdbarch, ia64_print_insn); set_gdbarch_convert_from_func_ptr_addr (gdbarch, ia64_convert_from_func_ptr_addr); diff --git a/gdb/remote.c b/gdb/remote.c index d21b7b69f22..3dbb652901d 100644 --- a/gdb/remote.c +++ b/gdb/remote.c @@ -4108,12 +4108,6 @@ remote_write_bytes_aux (const char *header, CORE_ADDR memaddr, internal_error (__FILE__, __LINE__, "remote_write_bytes_aux: bad packet format"); - /* Should this be the selected frame? */ - gdbarch_remote_translate_xfer_address (current_gdbarch, - current_regcache, - memaddr, len, - &memaddr, &len); - if (len <= 0) return 0; @@ -4306,12 +4300,6 @@ remote_read_bytes (CORE_ADDR memaddr, gdb_byte *myaddr, int len) int max_buf_size; /* Max size of packet output buffer. */ int origlen; - /* Should this be the selected frame? */ - gdbarch_remote_translate_xfer_address (current_gdbarch, - current_regcache, - memaddr, len, - &memaddr, &len); - if (len <= 0) return 0;