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_extract_return_value_ftype *extract_return_value;
gdbarch_store_return_value_ftype *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_inner_than_ftype *inner_than;
gdbarch_breakpoint_from_pc_ftype *breakpoint_from_pc;
gdbarch_unwind_pc_ftype *unwind_pc;
gdbarch_unwind_sp_ftype *unwind_sp;
gdbarch_frame_num_args_ftype *frame_num_args;
- gdbarch_deprecated_stack_align_ftype *deprecated_stack_align;
gdbarch_frame_align_ftype *frame_align;
gdbarch_deprecated_reg_struct_has_addr_ftype *deprecated_reg_struct_has_addr;
gdbarch_stabs_argument_has_addr_ftype *stabs_argument_has_addr;
0, /* long_double_format */
8 * sizeof (void*), /* ptr_bit */
8 * sizeof (void*), /* addr_bit */
- 8 * sizeof (void*), /* bfd_vma_bit */
1, /* char_signed */
0, /* read_pc */
0, /* write_pc */
0, /* extract_return_value */
0, /* store_return_value */
0, /* deprecated_use_struct_convention */
- 0, /* deprecated_extract_struct_value_address */
0, /* skip_prologue */
0, /* inner_than */
0, /* breakpoint_from_pc */
0, /* unwind_pc */
0, /* unwind_sp */
0, /* frame_num_args */
- 0, /* deprecated_stack_align */
0, /* frame_align */
0, /* deprecated_reg_struct_has_addr */
default_stabs_argument_has_addr, /* stabs_argument_has_addr */
struct gdbarch_tdep *tdep)
{
/* NOTE: The new architecture variable is named ``current_gdbarch''
- so that macros such as TARGET_DOUBLE_BIT, when expanded, refer to
+ so that macros such as TARGET_ARCHITECTURE, when expanded, refer to
the current local architecture and not the previous global
architecture. This ensures that the new architectures initial
values are not influenced by the previous architecture. Once
current_gdbarch->double_bit = 8*TARGET_CHAR_BIT;
current_gdbarch->long_double_bit = 8*TARGET_CHAR_BIT;
current_gdbarch->ptr_bit = current_gdbarch->int_bit;
- current_gdbarch->bfd_vma_bit = TARGET_ARCHITECTURE->bits_per_address;
current_gdbarch->char_signed = -1;
- current_gdbarch->write_pc = generic_target_write_pc;
current_gdbarch->virtual_frame_pointer = legacy_virtual_frame_pointer;
current_gdbarch->num_regs = -1;
current_gdbarch->sp_regnum = -1;
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;
- /* Skip verify of bfd_vma_bit, invalid_p == 0 */
+ current_gdbarch->addr_bit = gdbarch_ptr_bit (current_gdbarch);
if (current_gdbarch->char_signed == -1)
current_gdbarch->char_signed = 1;
/* Skip verify of read_pc, has predicate */
- /* Skip verify of write_pc, invalid_p == 0 */
+ /* Skip verify of write_pc, 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 integer_to_address, has predicate */
/* Skip verify of return_value, has predicate */
/* 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)
fprintf_unfiltered (log, "\n\tskip_prologue");
if (current_gdbarch->inner_than == 0)
/* Skip verify of unwind_pc, has predicate */
/* Skip verify of unwind_sp, has predicate */
/* Skip verify of frame_num_args, has predicate */
- /* Skip verify of deprecated_stack_align, has predicate */
/* Skip verify of frame_align, has predicate */
/* Skip verify of deprecated_reg_struct_has_addr, has predicate */
/* Skip verify of stabs_argument_has_addr, invalid_p == 0 */
fprintf_unfiltered (file,
"gdbarch_dump: GDB_TM_FILE = %s\n",
gdb_tm_file);
-#ifdef TARGET_ADDR_BIT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_ADDR_BIT # %s\n",
- XSTRING (TARGET_ADDR_BIT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: addr_bit = %s\n",
paddr_d (current_gdbarch->addr_bit));
fprintf_unfiltered (file,
"gdbarch_dump: believe_pcc_promotion = %s\n",
paddr_d (current_gdbarch->believe_pcc_promotion));
-#ifdef TARGET_ARCHITECTURE
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_ARCHITECTURE # %s\n",
- XSTRING (TARGET_ARCHITECTURE));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: bfd_arch_info = %s\n",
- TARGET_ARCHITECTURE->printable_name);
-#ifdef TARGET_BFD_VMA_BIT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_BFD_VMA_BIT # %s\n",
- XSTRING (TARGET_BFD_VMA_BIT));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: bfd_vma_bit = %s\n",
- paddr_d (current_gdbarch->bfd_vma_bit));
-#ifdef BREAKPOINT_FROM_PC
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "BREAKPOINT_FROM_PC(pcptr, lenptr)",
- XSTRING (BREAKPOINT_FROM_PC (pcptr, lenptr)));
-#endif
+ gdbarch_bfd_arch_info (current_gdbarch)->printable_name);
fprintf_unfiltered (file,
"gdbarch_dump: breakpoint_from_pc = <0x%lx>\n",
(long) current_gdbarch->breakpoint_from_pc);
fprintf_unfiltered (file,
"gdbarch_dump: convert_from_func_ptr_addr = <0x%lx>\n",
(long) current_gdbarch->convert_from_func_ptr_addr);
-#ifdef CONVERT_REGISTER_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "CONVERT_REGISTER_P(regnum, type)",
- XSTRING (CONVERT_REGISTER_P (regnum, type)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: convert_register_p = <0x%lx>\n",
(long) current_gdbarch->convert_register_p);
fprintf_unfiltered (file,
"gdbarch_dump: decr_pc_after_break = 0x%s\n",
paddr_nz (current_gdbarch->decr_pc_after_break));
-#ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P()",
- XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_deprecated_extract_struct_value_address_p() = %d\n",
- gdbarch_deprecated_extract_struct_value_address_p (current_gdbarch));
-#ifdef DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS(regcache)",
- XSTRING (DEPRECATED_EXTRACT_STRUCT_VALUE_ADDRESS (regcache)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_extract_struct_value_address = <0x%lx>\n",
- (long) current_gdbarch->deprecated_extract_struct_value_address);
-#ifdef DEPRECATED_FP_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: DEPRECATED_FP_REGNUM # %s\n",
- XSTRING (DEPRECATED_FP_REGNUM));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_fp_regnum = %s\n",
paddr_d (current_gdbarch->deprecated_fp_regnum));
-#ifdef DEPRECATED_FUNCTION_START_OFFSET
- fprintf_unfiltered (file,
- "gdbarch_dump: DEPRECATED_FUNCTION_START_OFFSET # %s\n",
- XSTRING (DEPRECATED_FUNCTION_START_OFFSET));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_function_start_offset = 0x%s\n",
paddr_nz (current_gdbarch->deprecated_function_start_offset));
-#ifdef DEPRECATED_REG_STRUCT_HAS_ADDR_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REG_STRUCT_HAS_ADDR_P()",
- XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR_P ()));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: gdbarch_deprecated_reg_struct_has_addr_p() = %d\n",
gdbarch_deprecated_reg_struct_has_addr_p (current_gdbarch));
-#ifdef DEPRECATED_REG_STRUCT_HAS_ADDR
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REG_STRUCT_HAS_ADDR(gcc_p, type)",
- XSTRING (DEPRECATED_REG_STRUCT_HAS_ADDR (gcc_p, type)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_reg_struct_has_addr = <0x%lx>\n",
(long) current_gdbarch->deprecated_reg_struct_has_addr);
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_register_size = %s\n",
paddr_d (current_gdbarch->deprecated_register_size));
-#ifdef DEPRECATED_STACK_ALIGN_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_STACK_ALIGN_P()",
- XSTRING (DEPRECATED_STACK_ALIGN_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_deprecated_stack_align_p() = %d\n",
- gdbarch_deprecated_stack_align_p (current_gdbarch));
-#ifdef DEPRECATED_STACK_ALIGN
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_STACK_ALIGN(sp)",
- XSTRING (DEPRECATED_STACK_ALIGN (sp)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_stack_align = <0x%lx>\n",
- (long) current_gdbarch->deprecated_stack_align);
-#ifdef DEPRECATED_USE_STRUCT_CONVENTION
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_USE_STRUCT_CONVENTION(gcc_p, value_type)",
- XSTRING (DEPRECATED_USE_STRUCT_CONVENTION (gcc_p, value_type)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_use_struct_convention = <0x%lx>\n",
(long) current_gdbarch->deprecated_use_struct_convention);
-#ifdef TARGET_DOUBLE_BIT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_DOUBLE_BIT # %s\n",
- XSTRING (TARGET_DOUBLE_BIT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: double_bit = %s\n",
paddr_d (current_gdbarch->double_bit));
-#ifdef TARGET_DOUBLE_FORMAT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_DOUBLE_FORMAT # %s\n",
- XSTRING (TARGET_DOUBLE_FORMAT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: double_format = %s\n",
pformat (current_gdbarch->double_format));
-#ifdef DWARF2_REG_TO_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DWARF2_REG_TO_REGNUM(dwarf2_regnr)",
- XSTRING (DWARF2_REG_TO_REGNUM (dwarf2_regnr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: dwarf2_reg_to_regnum = <0x%lx>\n",
(long) current_gdbarch->dwarf2_reg_to_regnum);
-#ifdef DWARF_REG_TO_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DWARF_REG_TO_REGNUM(dwarf_regnr)",
- XSTRING (DWARF_REG_TO_REGNUM (dwarf_regnr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: dwarf_reg_to_regnum = <0x%lx>\n",
(long) current_gdbarch->dwarf_reg_to_regnum);
-#ifdef ECOFF_REG_TO_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "ECOFF_REG_TO_REGNUM(ecoff_regnr)",
- XSTRING (ECOFF_REG_TO_REGNUM (ecoff_regnr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: ecoff_reg_to_regnum = <0x%lx>\n",
(long) current_gdbarch->ecoff_reg_to_regnum);
fprintf_unfiltered (file,
"gdbarch_dump: elf_make_msymbol_special = <0x%lx>\n",
(long) current_gdbarch->elf_make_msymbol_special);
-#ifdef EXTRACT_RETURN_VALUE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "EXTRACT_RETURN_VALUE(type, regcache, valbuf)",
- XSTRING (EXTRACT_RETURN_VALUE (type, regcache, valbuf)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: extract_return_value = <0x%lx>\n",
(long) current_gdbarch->extract_return_value);
fprintf_unfiltered (file,
"gdbarch_dump: fetch_tls_load_module_address = <0x%lx>\n",
(long) current_gdbarch->fetch_tls_load_module_address);
-#ifdef TARGET_FLOAT_BIT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_FLOAT_BIT # %s\n",
- XSTRING (TARGET_FLOAT_BIT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: float_bit = %s\n",
paddr_d (current_gdbarch->float_bit));
-#ifdef TARGET_FLOAT_FORMAT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_FLOAT_FORMAT # %s\n",
- XSTRING (TARGET_FLOAT_FORMAT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: float_format = %s\n",
pformat (current_gdbarch->float_format));
-#ifdef FP0_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: FP0_REGNUM # %s\n",
- XSTRING (FP0_REGNUM));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: fp0_regnum = %s\n",
paddr_d (current_gdbarch->fp0_regnum));
fprintf_unfiltered (file,
"gdbarch_dump: long_bit = %s\n",
paddr_d (current_gdbarch->long_bit));
-#ifdef TARGET_LONG_DOUBLE_BIT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_LONG_DOUBLE_BIT # %s\n",
- XSTRING (TARGET_LONG_DOUBLE_BIT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: long_double_bit = %s\n",
paddr_d (current_gdbarch->long_double_bit));
-#ifdef TARGET_LONG_DOUBLE_FORMAT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_LONG_DOUBLE_FORMAT # %s\n",
- XSTRING (TARGET_LONG_DOUBLE_FORMAT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: long_double_format = %s\n",
pformat (current_gdbarch->long_double_format));
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",
- XSTRING (PC_REGNUM));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: pc_regnum = %s\n",
paddr_d (current_gdbarch->pc_regnum));
fprintf_unfiltered (file,
"gdbarch_dump: print_vector_info = <0x%lx>\n",
(long) current_gdbarch->print_vector_info);
-#ifdef PS_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: PS_REGNUM # %s\n",
- XSTRING (PS_REGNUM));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: ps_regnum = %s\n",
paddr_d (current_gdbarch->ps_regnum));
fprintf_unfiltered (file,
"gdbarch_dump: pseudo_register_write = <0x%lx>\n",
(long) current_gdbarch->pseudo_register_write);
-#ifdef TARGET_PTR_BIT
- fprintf_unfiltered (file,
- "gdbarch_dump: TARGET_PTR_BIT # %s\n",
- XSTRING (TARGET_PTR_BIT));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: ptr_bit = %s\n",
paddr_d (current_gdbarch->ptr_bit));
fprintf_unfiltered (file,
"gdbarch_dump: push_dummy_code = <0x%lx>\n",
(long) current_gdbarch->push_dummy_code);
-#ifdef TARGET_READ_PC_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "TARGET_READ_PC_P()",
- XSTRING (TARGET_READ_PC_P ()));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: gdbarch_read_pc_p() = %d\n",
gdbarch_read_pc_p (current_gdbarch));
-#ifdef TARGET_READ_PC
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "TARGET_READ_PC(ptid)",
- XSTRING (TARGET_READ_PC (ptid)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: read_pc = <0x%lx>\n",
(long) current_gdbarch->read_pc);
fprintf_unfiltered (file,
"gdbarch_dump: register_reggroup_p = <0x%lx>\n",
(long) current_gdbarch->register_reggroup_p);
-#ifdef REGISTER_SIM_REGNO
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "REGISTER_SIM_REGNO(reg_nr)",
- XSTRING (REGISTER_SIM_REGNO (reg_nr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: register_sim_regno = <0x%lx>\n",
(long) current_gdbarch->register_sim_regno);
-#ifdef REGISTER_TO_VALUE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "REGISTER_TO_VALUE(frame, regnum, type, buf)",
- XSTRING (REGISTER_TO_VALUE (frame, regnum, type, buf)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: register_to_value = <0x%lx>\n",
(long) current_gdbarch->register_to_value);
fprintf_unfiltered (file,
"gdbarch_dump: return_value = <0x%lx>\n",
(long) current_gdbarch->return_value);
-#ifdef SDB_REG_TO_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "SDB_REG_TO_REGNUM(sdb_regnr)",
- XSTRING (SDB_REG_TO_REGNUM (sdb_regnr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: sdb_reg_to_regnum = <0x%lx>\n",
(long) current_gdbarch->sdb_reg_to_regnum);
fprintf_unfiltered (file,
"gdbarch_dump: skip_trampoline_code = <0x%lx>\n",
(long) current_gdbarch->skip_trampoline_code);
-#ifdef SMASH_TEXT_ADDRESS
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "SMASH_TEXT_ADDRESS(addr)",
- XSTRING (SMASH_TEXT_ADDRESS (addr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: smash_text_address = <0x%lx>\n",
(long) current_gdbarch->smash_text_address);
#ifdef SOFTWARE_SINGLE_STEP
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
- "SOFTWARE_SINGLE_STEP(regcache)",
- XSTRING (SOFTWARE_SINGLE_STEP (regcache)));
+ "SOFTWARE_SINGLE_STEP(frame)",
+ XSTRING (SOFTWARE_SINGLE_STEP (frame)));
#endif
fprintf_unfiltered (file,
"gdbarch_dump: software_single_step = <0x%lx>\n",
(long) current_gdbarch->software_single_step);
-#ifdef SP_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: SP_REGNUM # %s\n",
- XSTRING (SP_REGNUM));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: sp_regnum = %s\n",
paddr_d (current_gdbarch->sp_regnum));
-#ifdef STAB_REG_TO_REGNUM
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "STAB_REG_TO_REGNUM(stab_regnr)",
- XSTRING (STAB_REG_TO_REGNUM (stab_regnr)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: stab_reg_to_regnum = <0x%lx>\n",
(long) current_gdbarch->stab_reg_to_regnum);
fprintf_unfiltered (file,
"gdbarch_dump: stabs_argument_has_addr = <0x%lx>\n",
(long) current_gdbarch->stabs_argument_has_addr);
-#ifdef STORE_RETURN_VALUE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "STORE_RETURN_VALUE(type, regcache, valbuf)",
- XSTRING (STORE_RETURN_VALUE (type, regcache, valbuf)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: store_return_value = <0x%lx>\n",
(long) current_gdbarch->store_return_value);
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",
- "VALUE_TO_REGISTER(frame, regnum, type, buf)",
- XSTRING (VALUE_TO_REGISTER (frame, regnum, type, buf)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: value_to_register = <0x%lx>\n",
(long) current_gdbarch->value_to_register);
fprintf_unfiltered (file,
"gdbarch_dump: vbit_in_delta = %s\n",
paddr_d (current_gdbarch->vbit_in_delta));
-#ifdef TARGET_VIRTUAL_FRAME_POINTER
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "TARGET_VIRTUAL_FRAME_POINTER(pc, frame_regnum, frame_offset)",
- XSTRING (TARGET_VIRTUAL_FRAME_POINTER (pc, frame_regnum, frame_offset)));
-#endif
fprintf_unfiltered (file,
"gdbarch_dump: virtual_frame_pointer = <0x%lx>\n",
(long) current_gdbarch->virtual_frame_pointer);
fprintf_unfiltered (file,
"gdbarch_dump: vtable_function_descriptors = %s\n",
paddr_d (current_gdbarch->vtable_function_descriptors));
-#ifdef TARGET_WRITE_PC
fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "TARGET_WRITE_PC(val, ptid)",
- XSTRING (TARGET_WRITE_PC (val, ptid)));
-#endif
+ "gdbarch_dump: gdbarch_write_pc_p() = %d\n",
+ gdbarch_write_pc_p (current_gdbarch));
fprintf_unfiltered (file,
"gdbarch_dump: write_pc = <0x%lx>\n",
(long) current_gdbarch->write_pc);
gdbarch->addr_bit = addr_bit;
}
-int
-gdbarch_bfd_vma_bit (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- /* Skip verify of bfd_vma_bit, invalid_p == 0 */
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_bfd_vma_bit called\n");
- return gdbarch->bfd_vma_bit;
-}
-
-void
-set_gdbarch_bfd_vma_bit (struct gdbarch *gdbarch,
- int bfd_vma_bit)
-{
- gdbarch->bfd_vma_bit = bfd_vma_bit;
-}
-
int
gdbarch_char_signed (struct gdbarch *gdbarch)
{
}
CORE_ADDR
-gdbarch_read_pc (struct gdbarch *gdbarch, ptid_t ptid)
+gdbarch_read_pc (struct gdbarch *gdbarch, struct regcache *regcache)
{
gdb_assert (gdbarch != NULL);
gdb_assert (gdbarch->read_pc != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_read_pc called\n");
- return gdbarch->read_pc (ptid);
+ return gdbarch->read_pc (regcache);
}
void
gdbarch->read_pc = read_pc;
}
+int
+gdbarch_write_pc_p (struct gdbarch *gdbarch)
+{
+ gdb_assert (gdbarch != NULL);
+ return gdbarch->write_pc != NULL;
+}
+
void
-gdbarch_write_pc (struct gdbarch *gdbarch, CORE_ADDR val, ptid_t ptid)
+gdbarch_write_pc (struct gdbarch *gdbarch, struct regcache *regcache, CORE_ADDR val)
{
gdb_assert (gdbarch != NULL);
gdb_assert (gdbarch->write_pc != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_write_pc called\n");
- gdbarch->write_pc (val, ptid);
+ gdbarch->write_pc (regcache, val);
}
void
}
CORE_ADDR
-gdbarch_push_dummy_code (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, int using_gcc, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr)
+gdbarch_push_dummy_code (struct gdbarch *gdbarch, CORE_ADDR sp, CORE_ADDR funaddr, int using_gcc, struct value **args, int nargs, struct type *value_type, CORE_ADDR *real_pc, CORE_ADDR *bp_addr, struct regcache *regcache)
{
gdb_assert (gdbarch != NULL);
gdb_assert (gdbarch->push_dummy_code != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_push_dummy_code called\n");
- return gdbarch->push_dummy_code (gdbarch, sp, funaddr, using_gcc, args, nargs, value_type, real_pc, bp_addr);
+ return gdbarch->push_dummy_code (gdbarch, sp, funaddr, using_gcc, args, nargs, value_type, real_pc, bp_addr, regcache);
}
void
}
int
-gdbarch_get_longjmp_target (struct gdbarch *gdbarch, CORE_ADDR *pc)
+gdbarch_get_longjmp_target (struct gdbarch *gdbarch, struct frame_info *frame, CORE_ADDR *pc)
{
gdb_assert (gdbarch != NULL);
gdb_assert (gdbarch->get_longjmp_target != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_get_longjmp_target called\n");
- return gdbarch->get_longjmp_target (pc);
+ return gdbarch->get_longjmp_target (frame, pc);
}
void
gdbarch->deprecated_use_struct_convention = deprecated_use_struct_convention;
}
-int
-gdbarch_deprecated_extract_struct_value_address_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->deprecated_extract_struct_value_address != NULL;
-}
-
-CORE_ADDR
-gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch, struct regcache *regcache)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_extract_struct_value_address != NULL);
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_extract_struct_value_address called\n");
- return gdbarch->deprecated_extract_struct_value_address (regcache);
-}
-
-void
-set_gdbarch_deprecated_extract_struct_value_address (struct gdbarch *gdbarch,
- gdbarch_deprecated_extract_struct_value_address_ftype deprecated_extract_struct_value_address)
-{
- gdbarch->deprecated_extract_struct_value_address = deprecated_extract_struct_value_address;
-}
-
CORE_ADDR
gdbarch_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR ip)
{
gdbarch->frame_num_args = frame_num_args;
}
-int
-gdbarch_deprecated_stack_align_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->deprecated_stack_align != NULL;
-}
-
-CORE_ADDR
-gdbarch_deprecated_stack_align (struct gdbarch *gdbarch, CORE_ADDR sp)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_stack_align != NULL);
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_stack_align called\n");
- return gdbarch->deprecated_stack_align (sp);
-}
-
-void
-set_gdbarch_deprecated_stack_align (struct gdbarch *gdbarch,
- gdbarch_deprecated_stack_align_ftype deprecated_stack_align)
-{
- gdbarch->deprecated_stack_align = deprecated_stack_align;
-}
-
int
gdbarch_frame_align_p (struct gdbarch *gdbarch)
{
}
int
-gdbarch_software_single_step (struct gdbarch *gdbarch, struct regcache *regcache)
+gdbarch_software_single_step (struct gdbarch *gdbarch, struct frame_info *frame)
{
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");
- return gdbarch->software_single_step (regcache);
+ return gdbarch->software_single_step (frame);
}
void
}
CORE_ADDR
-gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, CORE_ADDR pc)
+gdbarch_skip_trampoline_code (struct gdbarch *gdbarch, struct frame_info *frame, CORE_ADDR pc)
{
gdb_assert (gdbarch != NULL);
gdb_assert (gdbarch->skip_trampoline_code != NULL);
if (gdbarch_debug >= 2)
fprintf_unfiltered (gdb_stdlog, "gdbarch_skip_trampoline_code called\n");
- return gdbarch->skip_trampoline_code (pc);
+ return gdbarch->skip_trampoline_code (frame, pc);
}
void