- if (TYPE_NFIELDS (type) == 1)
- return mn10300_use_struct_convention (TYPE_FIELD_TYPE (type, 0));
+ if (type->num_fields () == 1)
+ return mn10300_use_struct_convention (type->field (0).type ());
/* Structures with word or double-word size are passed in memory, as
long as they require at least word alignment. */
/* Structures with word or double-word size are passed in memory, as
long as they require at least word alignment. */
- CORE_ADDR start_pc, CORE_ADDR limit_pc,
- struct mn10300_prologue *result)
+ CORE_ADDR start_pc, CORE_ADDR limit_pc,
+ struct mn10300_prologue *result)
{
enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
CORE_ADDR pc;
int rn;
pv_t regs[MN10300_MAX_NUM_REGS];
CORE_ADDR after_last_frame_setup_insn = start_pc;
{
enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
CORE_ADDR pc;
int rn;
pv_t regs[MN10300_MAX_NUM_REGS];
CORE_ADDR after_last_frame_setup_insn = start_pc;
memset (result, 0, sizeof (*result));
result->gdbarch = gdbarch;
memset (result, 0, sizeof (*result));
result->gdbarch = gdbarch;
imm8 = extract_signed_integer (&instr[1], 1, byte_order);
regs[E_A0_REGNUM + aN] = pv_add_constant (regs[E_A0_REGNUM + aN],
imm8 = extract_signed_integer (&instr[1], 1, byte_order);
regs[E_A0_REGNUM + aN] = pv_add_constant (regs[E_A0_REGNUM + aN],
imm16 = extract_signed_integer (buf, 2, byte_order);
regs[E_A0_REGNUM + aN] = pv_add_constant (regs[E_A0_REGNUM + aN],
imm16 = extract_signed_integer (buf, 2, byte_order);
regs[E_A0_REGNUM + aN] = pv_add_constant (regs[E_A0_REGNUM + aN],
imm32 = extract_signed_integer (buf, 2, byte_order);
regs[E_A0_REGNUM + aN] = pv_add_constant (regs[E_A0_REGNUM + aN],
imm32 = extract_signed_integer (buf, 2, byte_order);
regs[E_A0_REGNUM + aN] = pv_add_constant (regs[E_A0_REGNUM + aN],
stop_addr = get_frame_pc (this_frame);
/* If we couldn't find any function containing the PC, then
stop_addr = get_frame_pc (this_frame);
/* If we couldn't find any function containing the PC, then
{
struct mn10300_prologue *p
= mn10300_analyze_frame_prologue (this_frame, this_prologue_cache);
{
struct mn10300_prologue *p
= mn10300_analyze_frame_prologue (this_frame, this_prologue_cache);
return a description of the stack slot holding it. */
if (p->reg_offset[regnum] != 1)
return frame_unwind_got_memory (this_frame, regnum,
return a description of the stack slot holding it. */
if (p->reg_offset[regnum] != 1)
return frame_unwind_got_memory (this_frame, regnum,
/* Otherwise, presume we haven't changed the value of this
register, and get it from the next frame. */
/* Otherwise, presume we haven't changed the value of this
register, and get it from the next frame. */
= gdbarch_unwind_sp (gdbarch, create_new_frame (sp, func_addr));
if (sp != unwound_sp)
regcache_cooked_write_unsigned (regcache, E_SP_REGNUM,
= gdbarch_unwind_sp (gdbarch, create_new_frame (sp, func_addr));
if (sp != unwound_sp)
regcache_cooked_write_unsigned (regcache, E_SP_REGNUM,
gdbarch = gdbarch_alloc (&info, tdep);
switch (info.bfd_arch_info->mach)
gdbarch = gdbarch_alloc (&info, tdep);
switch (info.bfd_arch_info->mach)
- struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
- fprintf_unfiltered (file, "mn10300_dump_tdep: am33_mode = %d\n",
- tdep->am33_mode);
+ mn10300_gdbarch_tdep *tdep = (mn10300_gdbarch_tdep *) gdbarch_tdep (gdbarch);
+ gdb_printf (file, "mn10300_dump_tdep: am33_mode = %d\n",
+ tdep->am33_mode);