#include "arch-utils.h"
#include "gdbcmd.h"
-#include "inferior.h" /* enum CALL_DUMMY_LOCATION et.al. */
+#include "inferior.h"
#include "symcat.h"
#include "floatformat.h"
}
static const char *
-pformat (const struct floatformat *format)
+pformat (const struct floatformat **format)
{
if (format == NULL)
return "(null)";
else
- return format->name;
+ /* Just print out one of them - this is only for diagnostics. */
+ return format[0]->name;
}
int long_bit;
int long_long_bit;
int float_bit;
- const struct floatformat * float_format;
+ const struct floatformat ** float_format;
int double_bit;
- const struct floatformat * double_format;
+ const struct floatformat ** double_format;
int long_double_bit;
- const struct floatformat * long_double_format;
+ const struct floatformat ** long_double_format;
int ptr_bit;
int addr_bit;
int bfd_vma_bit;
int char_signed;
gdbarch_read_pc_ftype *read_pc;
gdbarch_write_pc_ftype *write_pc;
- gdbarch_read_sp_ftype *read_sp;
gdbarch_virtual_frame_pointer_ftype *virtual_frame_pointer;
gdbarch_pseudo_register_read_ftype *pseudo_register_read;
gdbarch_pseudo_register_write_ftype *pseudo_register_write;
gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum;
gdbarch_register_name_ftype *register_name;
gdbarch_register_type_ftype *register_type;
- gdbarch_deprecated_register_byte_ftype *deprecated_register_byte;
gdbarch_unwind_dummy_id_ftype *unwind_dummy_id;
int deprecated_fp_regnum;
gdbarch_push_dummy_call_ftype *push_dummy_call;
gdbarch_convert_register_p_ftype *convert_register_p;
gdbarch_register_to_value_ftype *register_to_value;
gdbarch_value_to_register_ftype *value_to_register;
+ gdbarch_value_from_register_ftype *value_from_register;
gdbarch_pointer_to_address_ftype *pointer_to_address;
gdbarch_address_to_pointer_ftype *address_to_pointer;
gdbarch_integer_to_address_ftype *integer_to_address;
- gdbarch_deprecated_store_struct_return_ftype *deprecated_store_struct_return;
gdbarch_return_value_ftype *return_value;
gdbarch_extract_return_value_ftype *extract_return_value;
gdbarch_store_return_value_ftype *store_return_value;
- gdbarch_deprecated_extract_return_value_ftype *deprecated_extract_return_value;
- gdbarch_deprecated_store_return_value_ftype *deprecated_store_return_value;
gdbarch_deprecated_use_struct_convention_ftype *deprecated_use_struct_convention;
gdbarch_deprecated_extract_struct_value_address_ftype *deprecated_extract_struct_value_address;
gdbarch_skip_prologue_ftype *skip_prologue;
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;
gdbarch_unwind_pc_ftype *unwind_pc;
gdbarch_regset_from_core_section_ftype *regset_from_core_section;
int vtable_function_descriptors;
int vbit_in_delta;
+ gdbarch_skip_permanent_breakpoint_ftype *skip_permanent_breakpoint;
+ gdbarch_overlay_update_ftype *overlay_update;
};
1, /* char_signed */
0, /* read_pc */
0, /* write_pc */
- 0, /* read_sp */
0, /* virtual_frame_pointer */
0, /* pseudo_register_read */
0, /* pseudo_register_write */
0, /* dwarf2_reg_to_regnum */
0, /* register_name */
0, /* register_type */
- generic_register_byte, /* deprecated_register_byte */
0, /* unwind_dummy_id */
-1, /* deprecated_fp_regnum */
0, /* push_dummy_call */
0, /* convert_register_p */
0, /* register_to_value */
0, /* value_to_register */
+ 0, /* value_from_register */
0, /* pointer_to_address */
0, /* address_to_pointer */
0, /* integer_to_address */
- 0, /* deprecated_store_struct_return */
0, /* return_value */
0, /* extract_return_value */
0, /* store_return_value */
- 0, /* deprecated_extract_return_value */
- 0, /* deprecated_store_return_value */
0, /* deprecated_use_struct_convention */
0, /* deprecated_extract_struct_value_address */
0, /* skip_prologue */
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 */
0, /* unwind_pc */
0, /* regset_from_core_section */
0, /* vtable_function_descriptors */
0, /* vbit_in_delta */
+ 0, /* skip_permanent_breakpoint */
+ 0, /* overlay_update */
/* startup_gdbarch() */
};
current_gdbarch->dwarf_reg_to_regnum = no_op_reg_to_regnum;
current_gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum;
current_gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum;
- current_gdbarch->deprecated_register_byte = generic_register_byte;
current_gdbarch->deprecated_fp_regnum = -1;
current_gdbarch->call_dummy_location = AT_ENTRY_POINT;
current_gdbarch->print_registers_info = default_print_registers_info;
current_gdbarch->cannot_fetch_register = cannot_register_not;
current_gdbarch->cannot_store_register = cannot_register_not;
current_gdbarch->convert_register_p = generic_convert_register_p;
+ current_gdbarch->value_from_register = default_value_from_register;
current_gdbarch->pointer_to_address = unsigned_pointer_to_address;
current_gdbarch->address_to_pointer = unsigned_address_to_pointer;
current_gdbarch->return_value = legacy_return_value;
- current_gdbarch->extract_return_value = legacy_extract_return_value;
- current_gdbarch->store_return_value = legacy_store_return_value;
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;
current_gdbarch->addr_bits_remove = core_addr_identity;
/* Skip verify of long_long_bit, invalid_p == 0 */
/* Skip verify of float_bit, invalid_p == 0 */
if (current_gdbarch->float_format == 0)
- current_gdbarch->float_format = default_float_format (current_gdbarch);
+ current_gdbarch->float_format = floatformats_ieee_single;
/* Skip verify of double_bit, invalid_p == 0 */
if (current_gdbarch->double_format == 0)
- current_gdbarch->double_format = default_double_format (current_gdbarch);
+ current_gdbarch->double_format = floatformats_ieee_double;
/* Skip verify of long_double_bit, invalid_p == 0 */
if (current_gdbarch->long_double_format == 0)
- current_gdbarch->long_double_format = default_double_format (current_gdbarch);
+ current_gdbarch->long_double_format = floatformats_ieee_double;
/* Skip verify of ptr_bit, invalid_p == 0 */
if (current_gdbarch->addr_bit == 0)
current_gdbarch->addr_bit = TARGET_PTR_BIT;
current_gdbarch->char_signed = 1;
/* Skip verify of read_pc, has predicate */
/* Skip verify of write_pc, invalid_p == 0 */
- /* Skip verify of read_sp, has predicate */
/* Skip verify of virtual_frame_pointer, invalid_p == 0 */
/* Skip verify of pseudo_register_read, has predicate */
/* Skip verify of pseudo_register_write, has predicate */
/* Skip verify of sdb_reg_to_regnum, invalid_p == 0 */
/* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
/* Skip verify of register_type, has predicate */
- /* Skip verify of deprecated_register_byte, has predicate */
/* Skip verify of unwind_dummy_id, has predicate */
/* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
/* Skip verify of push_dummy_call, has predicate */
/* Skip verify of cannot_store_register, invalid_p == 0 */
/* Skip verify of get_longjmp_target, has predicate */
/* Skip verify of convert_register_p, invalid_p == 0 */
+ /* Skip verify of value_from_register, invalid_p == 0 */
/* Skip verify of pointer_to_address, invalid_p == 0 */
/* Skip verify of address_to_pointer, invalid_p == 0 */
/* Skip verify of integer_to_address, has predicate */
- /* Skip verify of deprecated_store_struct_return, has predicate */
/* Skip verify of return_value, has predicate */
- /* Skip verify of extract_return_value, invalid_p == 0 */
- /* Skip verify of store_return_value, invalid_p == 0 */
/* Skip verify of deprecated_use_struct_convention, invalid_p == 0 */
/* Skip verify of deprecated_extract_struct_value_address, has predicate */
if (current_gdbarch->skip_prologue == 0)
/* 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 */
/* Skip verify of unwind_pc, has predicate */
/* Skip verify of regset_from_core_section, has predicate */
/* Skip verify of vtable_function_descriptors, invalid_p == 0 */
/* Skip verify of vbit_in_delta, invalid_p == 0 */
+ /* Skip verify of skip_permanent_breakpoint, has predicate */
+ /* Skip verify of overlay_update, has predicate */
buf = ui_file_xstrdup (log, &dummy);
make_cleanup (xfree, buf);
if (strlen (buf) > 0)
fprintf_unfiltered (file,
"gdbarch_dump: address_class_type_flags_to_name = <0x%lx>\n",
(long) current_gdbarch->address_class_type_flags_to_name);
-#ifdef ADDRESS_TO_POINTER
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "ADDRESS_TO_POINTER(type, buf, addr)",
- XSTRING (ADDRESS_TO_POINTER (type, buf, addr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: address_to_pointer = <0x%lx>\n",
(long) current_gdbarch->address_to_pointer);
fprintf_unfiltered (file,
"gdbarch_dump: breakpoint_from_pc = <0x%lx>\n",
(long) current_gdbarch->breakpoint_from_pc);
-#ifdef TARGET_BYTE_ORDER
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_BYTE_ORDER # %s\n",
- XSTRING (TARGET_BYTE_ORDER));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: byte_order = %s\n",
paddr_d (current_gdbarch->byte_order));
-#ifdef CALL_DUMMY_LOCATION
- fprintf_unfiltered (file,
- "gdbarch_dump: CALL_DUMMY_LOCATION # %s\n",
- XSTRING (CALL_DUMMY_LOCATION));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: call_dummy_location = %s\n",
paddr_d (current_gdbarch->call_dummy_location));
-#ifdef CANNOT_FETCH_REGISTER
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "CANNOT_FETCH_REGISTER(regnum)",
- XSTRING (CANNOT_FETCH_REGISTER (regnum)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: cannot_fetch_register = <0x%lx>\n",
(long) current_gdbarch->cannot_fetch_register);
fprintf_unfiltered (file,
"gdbarch_dump: cannot_step_breakpoint = %s\n",
paddr_d (current_gdbarch->cannot_step_breakpoint));
-#ifdef CANNOT_STORE_REGISTER
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "CANNOT_STORE_REGISTER(regnum)",
- XSTRING (CANNOT_STORE_REGISTER (regnum)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: cannot_store_register = <0x%lx>\n",
(long) current_gdbarch->cannot_store_register);
-#ifdef TARGET_CHAR_SIGNED
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_CHAR_SIGNED # %s\n",
- XSTRING (TARGET_CHAR_SIGNED));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: char_signed = %s\n",
paddr_d (current_gdbarch->char_signed));
-#ifdef COFF_MAKE_MSYMBOL_SPECIAL
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "COFF_MAKE_MSYMBOL_SPECIAL(val, msym)",
- XSTRING (COFF_MAKE_MSYMBOL_SPECIAL (val, msym)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: coff_make_msymbol_special = <0x%lx>\n",
(long) current_gdbarch->coff_make_msymbol_special);
fprintf_unfiltered (file,
"gdbarch_dump: decr_pc_after_break = 0x%s\n",
paddr_nz (current_gdbarch->decr_pc_after_break));
-#ifdef DEPRECATED_EXTRACT_RETURN_VALUE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_EXTRACT_RETURN_VALUE(type, regbuf, valbuf)",
- XSTRING (DEPRECATED_EXTRACT_RETURN_VALUE (type, regbuf, valbuf)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_extract_return_value = <0x%lx>\n",
- (long) current_gdbarch->deprecated_extract_return_value);
#ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_reg_struct_has_addr = <0x%lx>\n",
(long) current_gdbarch->deprecated_reg_struct_has_addr);
-#ifdef DEPRECATED_REGISTER_BYTE_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REGISTER_BYTE_P()",
- XSTRING (DEPRECATED_REGISTER_BYTE_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_deprecated_register_byte_p() = %d\n",
- gdbarch_deprecated_register_byte_p (current_gdbarch));
-#ifdef DEPRECATED_REGISTER_BYTE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REGISTER_BYTE(reg_nr)",
- XSTRING (DEPRECATED_REGISTER_BYTE (reg_nr)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_register_byte = <0x%lx>\n",
- (long) current_gdbarch->deprecated_register_byte);
#ifdef DEPRECATED_REGISTER_SIZE
fprintf_unfiltered (file,
"gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n",
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_stack_align = <0x%lx>\n",
(long) current_gdbarch->deprecated_stack_align);
-#ifdef DEPRECATED_STORE_RETURN_VALUE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_STORE_RETURN_VALUE(type, valbuf)",
- XSTRING (DEPRECATED_STORE_RETURN_VALUE (type, valbuf)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_store_return_value = <0x%lx>\n",
- (long) current_gdbarch->deprecated_store_return_value);
-#ifdef DEPRECATED_STORE_STRUCT_RETURN_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_STORE_STRUCT_RETURN_P()",
- XSTRING (DEPRECATED_STORE_STRUCT_RETURN_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_deprecated_store_struct_return_p() = %d\n",
- gdbarch_deprecated_store_struct_return_p (current_gdbarch));
-#ifdef DEPRECATED_STORE_STRUCT_RETURN
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_STORE_STRUCT_RETURN(addr, sp)",
- XSTRING (DEPRECATED_STORE_STRUCT_RETURN (addr, sp)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_store_struct_return = <0x%lx>\n",
- (long) current_gdbarch->deprecated_store_struct_return);
#ifdef DEPRECATED_USE_STRUCT_CONVENTION
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
fprintf_unfiltered (file,
"gdbarch_dump: ecoff_reg_to_regnum = <0x%lx>\n",
(long) current_gdbarch->ecoff_reg_to_regnum);
-#ifdef ELF_MAKE_MSYMBOL_SPECIAL
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "ELF_MAKE_MSYMBOL_SPECIAL(sym, msym)",
- XSTRING (ELF_MAKE_MSYMBOL_SPECIAL (sym, msym)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: elf_make_msymbol_special = <0x%lx>\n",
(long) current_gdbarch->elf_make_msymbol_special);
fprintf_unfiltered (file,
"gdbarch_dump: frame_num_args = <0x%lx>\n",
(long) current_gdbarch->frame_num_args);
-#ifdef FRAME_RED_ZONE_SIZE
- fprintf_unfiltered (file,
- "gdbarch_dump: FRAME_RED_ZONE_SIZE # %s\n",
- XSTRING (FRAME_RED_ZONE_SIZE));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: frame_red_zone_size = %s\n",
paddr_d (current_gdbarch->frame_red_zone_size));
-#ifdef GET_LONGJMP_TARGET_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "GET_LONGJMP_TARGET_P()",
- XSTRING (GET_LONGJMP_TARGET_P ()));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: gdbarch_get_longjmp_target_p() = %d\n",
gdbarch_get_longjmp_target_p (current_gdbarch));
-#ifdef GET_LONGJMP_TARGET
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "GET_LONGJMP_TARGET(pc)",
- XSTRING (GET_LONGJMP_TARGET (pc)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: get_longjmp_target = <0x%lx>\n",
(long) current_gdbarch->get_longjmp_target);
fprintf_unfiltered (file,
"gdbarch_dump: in_solib_return_trampoline = <0x%lx>\n",
(long) current_gdbarch->in_solib_return_trampoline);
-#ifdef INNER_THAN
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "INNER_THAN(lhs, rhs)",
- XSTRING (INNER_THAN (lhs, rhs)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: inner_than = <0x%lx>\n",
(long) current_gdbarch->inner_than);
fprintf_unfiltered (file,
"gdbarch_dump: name_of_malloc = %s\n",
NAME_OF_MALLOC);
-#ifdef NUM_PSEUDO_REGS
- fprintf_unfiltered (file,
- "gdbarch_dump: NUM_PSEUDO_REGS # %s\n",
- XSTRING (NUM_PSEUDO_REGS));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: num_pseudo_regs = %s\n",
paddr_d (current_gdbarch->num_pseudo_regs));
-#ifdef NUM_REGS
- fprintf_unfiltered (file,
- "gdbarch_dump: NUM_REGS # %s\n",
- XSTRING (NUM_REGS));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: num_regs = %s\n",
paddr_d (current_gdbarch->num_regs));
-#ifdef TARGET_OSABI
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_OSABI # %s\n",
- XSTRING (TARGET_OSABI));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: osabi = %s\n",
paddr_d (current_gdbarch->osabi));
+ fprintf_unfiltered (file,
+ "gdbarch_dump: gdbarch_overlay_update_p() = %d\n",
+ gdbarch_overlay_update_p (current_gdbarch));
+ fprintf_unfiltered (file,
+ "gdbarch_dump: overlay_update = <0x%lx>\n",
+ (long) current_gdbarch->overlay_update);
#ifdef PC_REGNUM
fprintf_unfiltered (file,
"gdbarch_dump: PC_REGNUM # %s\n",
fprintf_unfiltered (file,
"gdbarch_dump: pc_regnum = %s\n",
paddr_d (current_gdbarch->pc_regnum));
-#ifdef POINTER_TO_ADDRESS
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "POINTER_TO_ADDRESS(type, buf)",
- XSTRING (POINTER_TO_ADDRESS (type, buf)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: pointer_to_address = <0x%lx>\n",
(long) current_gdbarch->pointer_to_address);
fprintf_unfiltered (file,
"gdbarch_dump: read_pc = <0x%lx>\n",
(long) current_gdbarch->read_pc);
-#ifdef TARGET_READ_SP_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "TARGET_READ_SP_P()",
- XSTRING (TARGET_READ_SP_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_read_sp_p() = %d\n",
- gdbarch_read_sp_p (current_gdbarch));
-#ifdef TARGET_READ_SP
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "TARGET_READ_SP()",
- XSTRING (TARGET_READ_SP ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: read_sp = <0x%lx>\n",
- (long) current_gdbarch->read_sp);
#ifdef REGISTER_BYTES_OK_P
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
"gdbarch_dump: regset_from_core_section = <0x%lx>\n",
(long) current_gdbarch->regset_from_core_section);
fprintf_unfiltered (file,
- "gdbarch_dump: remote_translate_xfer_address = <0x%lx>\n",
- (long) current_gdbarch->remote_translate_xfer_address);
+ "gdbarch_dump: remote_register_number = <0x%lx>\n",
+ (long) current_gdbarch->remote_register_number);
fprintf_unfiltered (file,
"gdbarch_dump: gdbarch_return_value_p() = %d\n",
gdbarch_return_value_p (current_gdbarch));
fprintf_unfiltered (file,
"gdbarch_dump: single_step_through_delay = <0x%lx>\n",
(long) current_gdbarch->single_step_through_delay);
+ fprintf_unfiltered (file,
+ "gdbarch_dump: gdbarch_skip_permanent_breakpoint_p() = %d\n",
+ gdbarch_skip_permanent_breakpoint_p (current_gdbarch));
+ fprintf_unfiltered (file,
+ "gdbarch_dump: skip_permanent_breakpoint = <0x%lx>\n",
+ (long) current_gdbarch->skip_permanent_breakpoint);
#ifdef SKIP_PROLOGUE
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
#ifdef SOFTWARE_SINGLE_STEP
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
- "SOFTWARE_SINGLE_STEP(sig, insert_breakpoints_p)",
- XSTRING (SOFTWARE_SINGLE_STEP (sig, insert_breakpoints_p)));
+ "SOFTWARE_SINGLE_STEP(regcache)",
+ XSTRING (SOFTWARE_SINGLE_STEP (regcache)));
#endif
fprintf_unfiltered (file,
"gdbarch_dump: software_single_step = <0x%lx>\n",
fprintf_unfiltered (file,
"gdbarch_dump: unwind_sp = <0x%lx>\n",
(long) current_gdbarch->unwind_sp);
+ fprintf_unfiltered (file,
+ "gdbarch_dump: value_from_register = <0x%lx>\n",
+ (long) current_gdbarch->value_from_register);
#ifdef VALUE_TO_REGISTER
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
gdbarch->float_bit = float_bit;
}
-const struct floatformat *
+const struct floatformat **
gdbarch_float_format (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
void
set_gdbarch_float_format (struct gdbarch *gdbarch,
- const struct floatformat * float_format)
+ const struct floatformat ** float_format)
{
gdbarch->float_format = float_format;
}
gdbarch->double_bit = double_bit;
}
-const struct floatformat *
+const struct floatformat **
gdbarch_double_format (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
void
set_gdbarch_double_format (struct gdbarch *gdbarch,
- const struct floatformat * double_format)
+ const struct floatformat ** double_format)
{
gdbarch->double_format = double_format;
}
gdbarch->long_double_bit = long_double_bit;
}
-const struct floatformat *
+const struct floatformat **
gdbarch_long_double_format (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
void
set_gdbarch_long_double_format (struct gdbarch *gdbarch,
- const struct floatformat * long_double_format)
+ const struct floatformat ** long_double_format)
{
gdbarch->long_double_format = long_double_format;
}
gdbarch->write_pc = write_pc;
}
-int
-gdbarch_read_sp_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->read_sp != NULL;
-}
-
-CORE_ADDR
-gdbarch_read_sp (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->read_sp != NULL);
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_read_sp called\n");
- return gdbarch->read_sp ();
-}
-
-void
-set_gdbarch_read_sp (struct gdbarch *gdbarch,
- gdbarch_read_sp_ftype read_sp)
-{
- gdbarch->read_sp = read_sp;
-}
-
void
gdbarch_virtual_frame_pointer (struct gdbarch *gdbarch, CORE_ADDR pc, int *frame_regnum, LONGEST *frame_offset)
{
}
int
-gdbarch_deprecated_register_byte_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->deprecated_register_byte != generic_register_byte;
-}
-
-int
-gdbarch_deprecated_register_byte (struct gdbarch *gdbarch, int reg_nr)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_register_byte != NULL);
- /* Do not check predicate: gdbarch->deprecated_register_byte != generic_register_byte, allow call. */
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_byte called\n");
- return gdbarch->deprecated_register_byte (reg_nr);
-}
-
-void
-set_gdbarch_deprecated_register_byte (struct gdbarch *gdbarch,
- gdbarch_deprecated_register_byte_ftype deprecated_register_byte)
-{
- gdbarch->deprecated_register_byte = deprecated_register_byte;
-}
-
-int
gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
gdbarch->value_to_register = value_to_register;
}
+struct value *
+gdbarch_value_from_register (struct gdbarch *gdbarch, struct type *type, int regnum, struct frame_info *frame)
+{
+ gdb_assert (gdbarch != NULL);
+ gdb_assert (gdbarch->value_from_register != NULL);
+ if (gdbarch_debug >= 2)
+ fprintf_unfiltered (gdb_stdlog, "gdbarch_value_from_register called\n");
+ return gdbarch->value_from_register (type, regnum, frame);
+}
+
+void
+set_gdbarch_value_from_register (struct gdbarch *gdbarch,
+ gdbarch_value_from_register_ftype value_from_register)
+{
+ gdbarch->value_from_register = value_from_register;
+}
+
CORE_ADDR
gdbarch_pointer_to_address (struct gdbarch *gdbarch, struct type *type, const gdb_byte *buf)
{
}
int
-gdbarch_deprecated_store_struct_return_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->deprecated_store_struct_return != NULL;
-}
-
-void
-gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch, CORE_ADDR addr, CORE_ADDR sp)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_store_struct_return != NULL);
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_struct_return called\n");
- gdbarch->deprecated_store_struct_return (addr, sp);
-}
-
-void
-set_gdbarch_deprecated_store_struct_return (struct gdbarch *gdbarch,
- gdbarch_deprecated_store_struct_return_ftype deprecated_store_struct_return)
-{
- gdbarch->deprecated_store_struct_return = deprecated_store_struct_return;
-}
-
-int
gdbarch_return_value_p (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
gdbarch->store_return_value = store_return_value;
}
-void
-gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch, struct type *type, gdb_byte *regbuf, gdb_byte *valbuf)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_extract_return_value != NULL);
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_return_value called\n");
- gdbarch->deprecated_extract_return_value (type, regbuf, valbuf);
-}
-
-void
-set_gdbarch_deprecated_extract_return_value (struct gdbarch *gdbarch,
- gdbarch_deprecated_extract_return_value_ftype deprecated_extract_return_value)
-{
- gdbarch->deprecated_extract_return_value = deprecated_extract_return_value;
-}
-
-void
-gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch, struct type *type, gdb_byte *valbuf)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_store_return_value != NULL);
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_store_return_value called\n");
- gdbarch->deprecated_store_return_value (type, valbuf);
-}
-
-void
-set_gdbarch_deprecated_store_return_value (struct gdbarch *gdbarch,
- gdbarch_deprecated_store_return_value_ftype deprecated_store_return_value)
-{
- gdbarch->deprecated_store_return_value = deprecated_store_return_value;
-}
-
int
gdbarch_deprecated_use_struct_convention (struct gdbarch *gdbarch, int gcc_p, struct type *value_type)
{
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)
+int
+gdbarch_remote_register_number (struct gdbarch *gdbarch, int regno)
{
gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->remote_translate_xfer_address != NULL);
+ gdb_assert (gdbarch->remote_register_number != 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);
+ fprintf_unfiltered (gdb_stdlog, "gdbarch_remote_register_number called\n");
+ return gdbarch->remote_register_number (gdbarch, regno);
}
void
-set_gdbarch_remote_translate_xfer_address (struct gdbarch *gdbarch,
- gdbarch_remote_translate_xfer_address_ftype remote_translate_xfer_address)
+set_gdbarch_remote_register_number (struct gdbarch *gdbarch,
+ gdbarch_remote_register_number_ftype remote_register_number)
{
- gdbarch->remote_translate_xfer_address = remote_translate_xfer_address;
+ gdbarch->remote_register_number = remote_register_number;
}
int
return gdbarch->software_single_step != NULL;
}
-void
-gdbarch_software_single_step (struct gdbarch *gdbarch, enum target_signal sig, int insert_breakpoints_p)
+int
+gdbarch_software_single_step (struct gdbarch *gdbarch, struct regcache *regcache)
{
gdb_assert (gdbarch != NULL);
gdb_assert (gdbarch->software_single_step != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_software_single_step called\n");
- gdbarch->software_single_step (sig, insert_breakpoints_p);
+ return gdbarch->software_single_step (regcache);
}
void
gdbarch->vbit_in_delta = vbit_in_delta;
}
+int
+gdbarch_skip_permanent_breakpoint_p (struct gdbarch *gdbarch)
+{
+ gdb_assert (gdbarch != NULL);
+ return gdbarch->skip_permanent_breakpoint != NULL;
+}
+
+void
+gdbarch_skip_permanent_breakpoint (struct gdbarch *gdbarch, struct regcache *regcache)
+{
+ gdb_assert (gdbarch != NULL);
+ gdb_assert (gdbarch->skip_permanent_breakpoint != NULL);
+ if (gdbarch_debug >= 2)
+ fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_permanent_breakpoint called\n");
+ gdbarch->skip_permanent_breakpoint (regcache);
+}
+
+void
+set_gdbarch_skip_permanent_breakpoint (struct gdbarch *gdbarch,
+ gdbarch_skip_permanent_breakpoint_ftype skip_permanent_breakpoint)
+{
+ gdbarch->skip_permanent_breakpoint = skip_permanent_breakpoint;
+}
+
+int
+gdbarch_overlay_update_p (struct gdbarch *gdbarch)
+{
+ gdb_assert (gdbarch != NULL);
+ return gdbarch->overlay_update != NULL;
+}
+
+void
+gdbarch_overlay_update (struct gdbarch *gdbarch, struct obj_section *osect)
+{
+ gdb_assert (gdbarch != NULL);
+ gdb_assert (gdbarch->overlay_update != NULL);
+ if (gdbarch_debug >= 2)
+ fprintf_unfiltered (gdb_stdlog, "gdbarch_overlay_update called\n");
+ gdbarch->overlay_update (osect);
+}
+
+void
+set_gdbarch_overlay_update (struct gdbarch *gdbarch,
+ gdbarch_overlay_update_ftype overlay_update)
+{
+ gdbarch->overlay_update = overlay_update;
+}
+
/* Keep a registry of per-architecture data-pointers required by GDB
modules. */
current_gdbarch_swap_out_hack ();
current_gdbarch_swap_in_hack (new_gdbarch);
architecture_changed_event ();
- flush_cached_frames ();
+ reinit_frame_cache ();
}
extern void _initialize_gdbarch (void);