45 #include "gdb/sim-sh.h"
127 static char *register_names[] =
131 "r0",
"r1",
"r2",
"r3",
"r4",
"r5",
"r6",
"r7",
132 "r8",
"r9",
"r10",
"r11",
"r12",
"r13",
"r14",
"r15",
133 "r16",
"r17",
"r18",
"r19",
"r20",
"r21",
"r22",
"r23",
134 "r24",
"r25",
"r26",
"r27",
"r28",
"r29",
"r30",
"r31",
135 "r32",
"r33",
"r34",
"r35",
"r36",
"r37",
"r38",
"r39",
136 "r40",
"r41",
"r42",
"r43",
"r44",
"r45",
"r46",
"r47",
137 "r48",
"r49",
"r50",
"r51",
"r52",
"r53",
"r54",
"r55",
138 "r56",
"r57",
"r58",
"r59",
"r60",
"r61",
"r62",
"r63",
147 "tr0",
"tr1",
"tr2",
"tr3",
"tr4",
"tr5",
"tr6",
"tr7",
153 "fr0",
"fr1",
"fr2",
"fr3",
"fr4",
"fr5",
"fr6",
"fr7",
154 "fr8",
"fr9",
"fr10",
"fr11",
"fr12",
"fr13",
"fr14",
"fr15",
155 "fr16",
"fr17",
"fr18",
"fr19",
"fr20",
"fr21",
"fr22",
"fr23",
156 "fr24",
"fr25",
"fr26",
"fr27",
"fr28",
"fr29",
"fr30",
"fr31",
157 "fr32",
"fr33",
"fr34",
"fr35",
"fr36",
"fr37",
"fr38",
"fr39",
158 "fr40",
"fr41",
"fr42",
"fr43",
"fr44",
"fr45",
"fr46",
"fr47",
159 "fr48",
"fr49",
"fr50",
"fr51",
"fr52",
"fr53",
"fr54",
"fr55",
160 "fr56",
"fr57",
"fr58",
"fr59",
"fr60",
"fr61",
"fr62",
"fr63",
163 "dr0",
"dr2",
"dr4",
"dr6",
"dr8",
"dr10",
"dr12",
"dr14",
164 "dr16",
"dr18",
"dr20",
"dr22",
"dr24",
"dr26",
"dr28",
"dr30",
165 "dr32",
"dr34",
"dr36",
"dr38",
"dr40",
"dr42",
"dr44",
"dr46",
166 "dr48",
"dr50",
"dr52",
"dr54",
"dr56",
"dr58",
"dr60",
"dr62",
169 "fp0",
"fp2",
"fp4",
"fp6",
"fp8",
"fp10",
"fp12",
"fp14",
170 "fp16",
"fp18",
"fp20",
"fp22",
"fp24",
"fp26",
"fp28",
"fp30",
171 "fp32",
"fp34",
"fp36",
"fp38",
"fp40",
"fp42",
"fp44",
"fp46",
172 "fp48",
"fp50",
"fp52",
"fp54",
"fp56",
"fp58",
"fp60",
"fp62",
175 "fv0",
"fv4",
"fv8",
"fv12",
"fv16",
"fv20",
"fv24",
"fv28",
176 "fv32",
"fv36",
"fv40",
"fv44",
"fv48",
"fv52",
"fv56",
"fv60",
179 "r0_c",
"r1_c",
"r2_c",
"r3_c",
"r4_c",
"r5_c",
"r6_c",
"r7_c",
180 "r8_c",
"r9_c",
"r10_c",
"r11_c",
"r12_c",
"r13_c",
"r14_c",
"r15_c",
182 "gbr_c",
"mach_c",
"macl_c",
"pr_c",
"t_c",
184 "fr0_c",
"fr1_c",
"fr2_c",
"fr3_c",
185 "fr4_c",
"fr5_c",
"fr6_c",
"fr7_c",
186 "fr8_c",
"fr9_c",
"fr10_c",
"fr11_c",
187 "fr12_c",
"fr13_c",
"fr14_c",
"fr15_c",
188 "dr0_c",
"dr2_c",
"dr4_c",
"dr6_c",
189 "dr8_c",
"dr10_c",
"dr12_c",
"dr14_c",
190 "fv0_c",
"fv4_c",
"fv8_c",
"fv12_c",
196 if (reg_nr >= (
sizeof (register_names) /
sizeof (*register_names)))
198 return register_names[reg_nr];
201 #define NUM_PSEUDO_REGS_SH_MEDIA 80
202 #define NUM_PSEUDO_REGS_SH_COMPACT 51
213 #define MSYMBOL_IS_SPECIAL(msym) \
214 MSYMBOL_TARGET_FLAG_1 (msym)
222 if (((elf_symbol_type *)(sym))->internal_elf_sym.st_other == STO_SH5_ISA32)
231 #define IS_ISA32_ADDR(addr) ((addr) & 1)
232 #define MAKE_ISA32_ADDR(addr) ((addr) | 1)
233 #define UNMAKE_ISA32_ADDR(addr) ((addr) & ~1)
255 static const unsigned char *
273 static unsigned char big_breakpoint_media[] = {
274 0x6f, 0xf5, 0xff, 0xf0
277 *lenptr =
sizeof (big_breakpoint_media);
278 return big_breakpoint_media;
282 static unsigned char big_breakpoint_compact[] = {0x0, 0x3b};
283 *lenptr =
sizeof (big_breakpoint_compact);
284 return big_breakpoint_compact;
291 static unsigned char little_breakpoint_media[] = {
292 0xf0, 0xff, 0xf5, 0x6f
295 *lenptr =
sizeof (little_breakpoint_media);
296 return little_breakpoint_media;
300 static unsigned char little_breakpoint_compact[] = {0x3b, 0x0};
301 *lenptr =
sizeof (little_breakpoint_compact);
302 return little_breakpoint_compact;
333 #define IS_PTABSL_R18(x) (((x) & 0xffffff8f) == 0x6bf14a00)
337 #define IS_STS_R0(x) ((x) == 0x4022)
341 #define IS_STS_PR(x) (((x) & 0xf0ff) == 0x2a)
345 #define IS_MOV_TO_R15(x) (((x) & 0xff00) == 0x1f00)
349 #define IS_MOV_R14(x) (((x) & 0xfff0) == 0x1fe0)
353 #define IS_STQ_R18_R14(x) (((x) & 0xfff003ff) == 0xace00120)
357 #define IS_STQ_R18_R15(x) (((x) & 0xfff003ff) == 0xacf00120)
361 #define IS_STL_R18_R15(x) (((x) & 0xfff003ff) == 0xa8f00120)
365 #define IS_STQ_R14_R15(x) (((x) & 0xfff003ff) == 0xacf000e0)
369 #define IS_STL_R14_R15(x) (((x) & 0xfff003ff) == 0xa8f000e0)
373 #define IS_ADDIL_SP_MEDIA(x) (((x) & 0xfff003ff) == 0xd4f000f0)
377 #define IS_ADDI_SP_MEDIA(x) (((x) & 0xfff003ff) == 0xd0f000f0)
381 #define IS_ADDL_SP_FP_MEDIA(x) ((x) == 0x00f8fce0)
385 #define IS_ADD_SP_FP_MEDIA(x) ((x) == 0x00f9fce0)
387 #define IS_MOV_SP_FP_MEDIA(x) \
388 (IS_ADDL_SP_FP_MEDIA(x) || IS_ADD_SP_FP_MEDIA(x))
392 #define IS_MOV_R0(x) (((x) & 0xff00) == 0xe000)
395 #define IS_MOVL_R0(x) (((x) & 0xff00) == 0xd000)
399 #define IS_ADD_SP_R0(x) ((x) == 0x30fc)
403 #define IS_MOV_R14_R0(x) ((x) == 0x20e6)
408 #define IS_MEDIA_IND_ARG_MOV(x) \
409 ((((x) & 0xfc0ffc0f) == 0x0009fc00) \
410 && (((x) & 0x03f00000) >= 0x00200000 \
411 && ((x) & 0x03f00000) <= 0x00900000))
416 #define IS_MEDIA_ARG_MOV(x) \
417 (((((x) & 0xfc0ffc0f) == 0xac000000) || (((x) & 0xfc0ffc0f) == 0xa8000000)) \
418 && (((x) & 0x000003f0) >= 0x00000020 && ((x) & 0x000003f0) <= 0x00000090))
425 #define IS_MEDIA_MOV_TO_R14(x) \
426 ((((x) & 0xfffffc0f) == 0xa0e00000) \
427 || (((x) & 0xfffffc0f) == 0xa4e00000) \
428 || (((x) & 0xfffffc0f) == 0xa8e00000) \
429 || (((x) & 0xfffffc0f) == 0xb4e00000) \
430 || (((x) & 0xfffffc0f) == 0xbce00000))
434 #define IS_COMPACT_IND_ARG_MOV(x) \
435 ((((x) & 0xf00f) == 0x6003) && (((x) & 0x00f0) >= 0x0020) \
436 && (((x) & 0x00f0) <= 0x0090))
440 #define IS_COMPACT_ARG_MOV(x) \
441 (((((x) & 0xff0f) == 0x2e02) && (((x) & 0x00f0) >= 0x0020) \
442 && ((x) & 0x00f0) <= 0x0090))
446 #define IS_COMPACT_MOV_TO_R14(x) \
447 ((((x) & 0xff0f) == 0x2e00) || (((x) & 0xff0f) == 0x2e01))
449 #define IS_JSR_R0(x) ((x) == 0x400b)
450 #define IS_NOP(x) ((x) == 0x0009)
455 #define IS_MOV_SP_FP(x) ((x) == 0x6ef3)
459 #define IS_ADD_SP(x) (((x) & 0xff00) == 0x7f00)
486 if (sal.
end < func_end)
499 int insn_size = (media_mode ? 4 : 2);
501 for (here = start_pc, end = start_pc + (insn_size * 28); here <
end;)
506 insn_size, byte_order);
515 insn_size, byte_order);
612 for (here = start_pc, end = start_pc + (insn_size * 28); here <
end;)
618 insn_size, byte_order);
639 here - insn_size, media_mode);
666 here - insn_size, media_mode);
687 if (post_prologue_pc != 0)
688 return max (pc, post_prologue_pc);
795 int base_regnum = reg_nr;
847 value = value & ((1 <<
bits) - 1);
848 return (value & (1 << (bits - 1))
849 ? value | (~((1 << bits) - 1))
864 int gdb_register_number;
882 opc = pc + (insn_size * 28);
883 if (opc > current_pc)
885 for ( ; pc <= opc; pc += insn_size)
889 insn_size, byte_order);
896 insn_size, byte_order);
900 = cache->
sp_offset - ((((next_insn & 0xf) ^ 0x8)
908 cache->
sp_offset - ((((insn & 0xf) ^ 0x8) - 0x8) << 2);
916 r0_val = ((insn & 0xff) ^ 0x80) - 0x80;
941 cache->
sp_offset -= ((insn & 0xff) ^ 0x80) - 0x80;
950 sign_extend ((((insn & 0xffc00) ^ 0x80000) - 0x80000) >> 10, 9);
1051 struct value *
function,
1054 int nargs,
struct value **args,
1059 int stack_offset, stack_alloc;
1063 int float_arg_index = 0;
1064 int double_arg_index = 0;
1074 memset (fp_args, 0,
sizeof (fp_args));
1087 for (argnum = 0, stack_alloc = 0; argnum < nargs; argnum++)
1099 for (argnum = 0, stack_offset = 0; argnum < nargs; argnum++)
1103 memset (valbuf, 0,
sizeof (valbuf));
1109 if (len < argreg_size)
1113 memcpy (valbuf + argreg_size - len,
1140 int_argreg, regval);
1157 while (fp_args[float_arg_index])
1170 fp_args[float_arg_index] = 1;
1183 while (fp_args[double_arg_index])
1184 double_arg_index += 2;
1193 int double_register_offset = double_arg_index / 2;
1196 fp_args[double_arg_index] = 1;
1197 fp_args[double_arg_index + 1] = 1;
1271 memcpy (valbuf, buf + offset, len);
1274 error (
_(
"bad size for return value"));
1296 for (i = 0; i <
len; i += 4)
1299 valbuf + len - 4 - i);
1318 memcpy (buf + offset, valbuf, len);
1408 static struct type *
1417 static struct type *
1469 error (
_(
"sh64_register_convert_to_virtual "
1470 "called with non DR register number"));
1494 error (
_(
"sh64_register_convert_to_raw called "
1495 "with non DR register number"));
1509 for (portion = 0; portion < portions; portion++)
1514 b = buffer +
register_size (gdbarch, base_regnum) * portion;
1542 2, base_regnum, temp_buffer);
1548 temp_buffer, buffer);
1563 2, base_regnum, buffer);
1575 4, base_regnum, buffer);
1591 temp_buffer + offset, 4);
1614 2, base_regnum, temp_buffer);
1620 temp_buffer, buffer);
1634 4, base_regnum, buffer);
1639 int fpscr_base_regnum;
1641 unsigned int fpscr_value;
1642 unsigned int sr_value;
1643 unsigned int fpscr_c_value;
1644 unsigned int fpscr_c_part1_value;
1645 unsigned int fpscr_c_part2_value;
1677 fpscr_c_part1_value = fpscr_value & 0x3fffd;
1678 fpscr_c_part2_value = (sr_value & 0x7000) << 6;
1679 fpscr_c_value = fpscr_c_part1_value | fpscr_c_part2_value;
1704 int base_regnum, portion;
1715 buffer, temp_buffer);
1718 for (portion = 0; portion < 2; portion++)
1722 base_regnum) * portion));
1731 for (portion = 0; portion < 2; portion++)
1734 base_regnum) * portion));
1743 for (portion = 0; portion < 4; portion++)
1746 base_regnum) * portion));
1765 memcpy (temp_buffer + offset, buffer, 4);
1782 for (portion = 0; portion < 2; portion++)
1788 buffer, temp_buffer);
1793 base_regnum) * portion));
1802 for (portion = 0; portion < 4; portion++)
1807 base_regnum) * portion));
1813 int fpscr_base_regnum;
1815 unsigned int fpscr_value;
1816 unsigned int sr_value;
1817 unsigned int old_fpscr_value;
1818 unsigned int old_sr_value;
1819 unsigned int fpscr_c_value;
1820 unsigned int fpscr_mask;
1821 unsigned int sr_mask;
1843 fpscr_mask = 0x0003fffd;
1844 sr_mask = 0x001c0000;
1846 fpscr_value = fpscr_c_value & fpscr_mask;
1847 sr_value = (fpscr_value & sr_mask) >> 6;
1851 old_fpscr_value &= 0xfffc0002;
1852 fpscr_value |= old_fpscr_value;
1858 old_sr_value &= 0xffff8fff;
1859 sr_value |= old_sr_value;
1878 switch (cr_c_regnum)
1919 unsigned char *raw_buffer;
1925 raw_buffer = (
unsigned char *)
1930 error (
_(
"can't read register %d (%s)"),
1940 (gdbarch, regnum)), file);
1968 _(
"Invalid pseudo register number %d\n"), regnum);
2038 (gdbarch, regnum)), file);
2066 _(
"Invalid register number %d\n"), regnum);
2089 error (
_(
"Not a valid register for the current processor type"));
2147 error (
_(
"Not a valid register for the current processor type"));
2150 error (
_(
"Not a valid register for the current processor mode."));
2196 for (i = 0; i < SIM_SH64_NR_REGS; i++)
2207 struct gdbarch *gdbarch;
2217 *this_cache = cache;
2228 if (cache->
base == 0)
2254 for (i = 0; i < SIM_SH64_NR_REGS; i++)
2261 static struct value *
2263 void **this_cache,
int regnum)
2280 if (regnum < SIM_SH64_NR_REGS && cache->saved_regs[regnum] != -1)
2305 if (cache->
base == 0)
2354 sh64_frame_base_address
2361 struct gdbarch *gdbarch;
2375 if (info.
abfd && bfd_get_arch_size (info.
abfd) == 64)
void set_gdbarch_num_regs(struct gdbarch *gdbarch, int num_regs)
void set_gdbarch_double_bit(struct gdbarch *gdbarch, int double_bit)
void set_gdbarch_frame_align(struct gdbarch *gdbarch, gdbarch_frame_align_ftype frame_align)
ULONGEST extract_unsigned_integer(const gdb_byte *, int, enum bfd_endian)
static CORE_ADDR sh64_skip_prologue_hard_way(struct gdbarch *gdbarch, CORE_ADDR start_pc)
static enum register_status sh64_pseudo_register_read(struct gdbarch *gdbarch, struct regcache *regcache, int reg_nr, gdb_byte *buffer)
#define IS_MEDIA_IND_ARG_MOV(x)
static void sh64_do_cr_c_register_info(struct ui_file *file, struct frame_info *frame, int cr_c_regnum)
struct type * lookup_array_range_type(struct type *element_type, LONGEST low_bound, LONGEST high_bound)
struct frame_id frame_id_build(CORE_ADDR stack_addr, CORE_ADDR code_addr)
static CORE_ADDR sh64_push_dummy_call(struct gdbarch *gdbarch, struct value *function, struct regcache *regcache, CORE_ADDR bp_addr, int nargs, struct value **args, CORE_ADDR sp, int struct_return, CORE_ADDR struct_addr)
static int sign_extend(int value, int bits)
static void sh64_elf_make_msymbol_special(asymbol *sym, struct minimal_symbol *msym)
void set_gdbarch_float_bit(struct gdbarch *gdbarch, int float_bit)
CORE_ADDR get_frame_pc(struct frame_info *frame)
void set_gdbarch_fp0_regnum(struct gdbarch *gdbarch, int fp0_regnum)
void floatformat_from_doublest(const struct floatformat *fmt, const DOUBLEST *in, void *out)
#define IS_STQ_R18_R15(x)
void gdbarch_init_osabi(struct gdbarch_info info, struct gdbarch *gdbarch)
static void sh64_pseudo_register_write(struct gdbarch *gdbarch, struct regcache *regcache, int reg_nr, const gdb_byte *buffer)
#define IS_STL_R14_R15(x)
#define IS_MEDIA_MOV_TO_R14(x)
struct gdbarch * get_regcache_arch(const struct regcache *regcache)
static const struct frame_unwind sh64_frame_unwind
struct value * frame_unwind_got_memory(struct frame_info *frame, int regnum, CORE_ADDR addr)
#define SET_MSYMBOL_VALUE_ADDRESS(symbol, new_value)
#define IS_MOV_SP_FP_MEDIA(x)
ULONGEST frame_unwind_register_unsigned(struct frame_info *frame, int regnum)
void set_gdbarch_short_bit(struct gdbarch *gdbarch, int short_bit)
void get_formatted_print_options(struct value_print_options *opts, char format)
const struct builtin_type * builtin_type(struct gdbarch *gdbarch)
void internal_error(const char *file, int line, const char *fmt,...)
static const char * sh64_register_name(struct gdbarch *gdbarch, int reg_nr)
static enum register_status pseudo_register_read_portions(struct gdbarch *gdbarch, struct regcache *regcache, int portions, int base_regnum, gdb_byte *buffer)
struct gdbarch_list * gdbarch_list_lookup_by_info(struct gdbarch_list *arches, const struct gdbarch_info *info)
DOUBLEST unpack_double(struct type *type, const gdb_byte *valaddr, int *invp)
int gdbarch_num_regs(struct gdbarch *gdbarch)
#define MSYMBOL_TARGET_FLAG_1(msymbol)
static void sh64_register_convert_to_raw(struct gdbarch *gdbarch, struct type *type, int regnum, const void *from, void *to)
#define bits(obj, st, fn)
struct gdbarch_tdep * gdbarch_tdep(struct gdbarch *gdbarch)
DOUBLEST extract_typed_floating(const void *addr, const struct type *type)
static int sh64_use_struct_convention(struct type *type)
void frame_unwind_append_unwinder(struct gdbarch *gdbarch, const struct frame_unwind *unwinder)
void set_gdbarch_print_registers_info(struct gdbarch *gdbarch, gdbarch_print_registers_info_ftype print_registers_info)
static struct type * sh64_build_float_register_type(struct gdbarch *gdbarch, int high)
void set_gdbarch_elf_make_msymbol_special(struct gdbarch *gdbarch, gdbarch_elf_make_msymbol_special_ftype elf_make_msymbol_special)
#define NUM_PSEUDO_REGS_SH_MEDIA
void floatformat_to_doublest(const struct floatformat *fmt, const void *in, DOUBLEST *out)
static void sh64_media_print_registers_info(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int fpregs)
#define FRAME_OBSTACK_ZALLOC(TYPE)
void store_unsigned_integer(gdb_byte *, int, enum bfd_endian, ULONGEST)
struct value * frame_unwind_got_constant(struct frame_info *frame, int regnum, ULONGEST val)
int gdbarch_num_pseudo_regs(struct gdbarch *gdbarch)
#define IS_COMPACT_MOV_TO_R14(x)
#define MSYMBOL_VALUE_RAW_ADDRESS(symbol)
void frame_base_set_default(struct gdbarch *gdbarch, const struct frame_base *default_base)
void set_gdbarch_pseudo_register_write(struct gdbarch *gdbarch, gdbarch_pseudo_register_write_ftype pseudo_register_write)
void set_gdbarch_register_type(struct gdbarch *gdbarch, gdbarch_register_type_ftype register_type)
LONGEST read_memory_integer(CORE_ADDR memaddr, int len, enum bfd_endian byte_order)
const gdb_byte * value_contents(struct value *value)
static CORE_ADDR sh64_skip_prologue(struct gdbarch *gdbarch, CORE_ADDR pc)
#define UNMAKE_ISA32_ADDR(addr)
static void sh64_analyze_prologue(struct gdbarch *gdbarch, struct sh64_frame_cache *cache, CORE_ADDR func_pc, CORE_ADDR current_pc)
#define IS_ADDIL_SP_MEDIA(x)
static void sh64_register_convert_to_virtual(struct gdbarch *gdbarch, int regnum, struct type *type, gdb_byte *from, gdb_byte *to)
struct symtab_and_line find_pc_line(CORE_ADDR pc, int notcurrent)
int gdbarch_sp_regnum(struct gdbarch *gdbarch)
void fprintf_filtered(struct ui_file *stream, const char *format,...)
void set_gdbarch_sp_regnum(struct gdbarch *gdbarch, int sp_regnum)
struct type * register_type(struct gdbarch *gdbarch, int regnum)
void set_gdbarch_dummy_id(struct gdbarch *gdbarch, gdbarch_dummy_id_ftype dummy_id)
mach_port_t mach_port_t name mach_port_t mach_port_t name error_t int status
int legacy_register_sim_regno(struct gdbarch *gdbarch, int regnum)
void set_gdbarch_believe_pcc_promotion(struct gdbarch *gdbarch, int believe_pcc_promotion)
void fputs_filtered(const char *linebuffer, struct ui_file *stream)
#define gdb_assert_not_reached(message)
static struct frame_id sh64_dummy_id(struct gdbarch *gdbarch, struct frame_info *this_frame)
enum bfd_endian gdbarch_byte_order(struct gdbarch *gdbarch)
void set_gdbarch_register_sim_regno(struct gdbarch *gdbarch, gdbarch_register_sim_regno_ftype register_sim_regno)
static struct type * sh64_register_type(struct gdbarch *gdbarch, int reg_nr)
int find_pc_partial_function(CORE_ADDR pc, const char **name, CORE_ADDR *address, CORE_ADDR *endaddr)
#define IS_MEDIA_ARG_MOV(x)
void set_gdbarch_unwind_pc(struct gdbarch *gdbarch, gdbarch_unwind_pc_ftype unwind_pc)
void set_gdbarch_breakpoint_from_pc(struct gdbarch *gdbarch, gdbarch_breakpoint_from_pc_ftype breakpoint_from_pc)
int default_frame_sniffer(const struct frame_unwind *self, struct frame_info *this_frame, void **this_prologue_cache)
static void sh64_extract_return_value(struct type *type, struct regcache *regcache, void *valbuf)
const char * gdbarch_register_name(struct gdbarch *gdbarch, int regnr)
static enum return_value_convention sh64_return_value(struct gdbarch *gdbarch, struct value *function, struct type *type, struct regcache *regcache, gdb_byte *readbuf, const gdb_byte *writebuf)
void set_gdbarch_unwind_sp(struct gdbarch *gdbarch, gdbarch_unwind_sp_ftype unwind_sp)
static void sh64_print_registers_info(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int fpregs)
static void sh64_print_register(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum)
static CORE_ADDR after_prologue(CORE_ADDR pc)
#define IS_STQ_R14_R15(x)
ULONGEST get_frame_register_unsigned(struct frame_info *frame, int regnum)
static int sh64_compact_reg_base_num(struct gdbarch *gdbarch, int reg_nr)
struct gdbarch * sh64_gdbarch_init(struct gdbarch_info info, struct gdbarch_list *arches)
CORE_ADDR saved_regs[SIM_SH64_NR_REGS]
void set_gdbarch_long_long_bit(struct gdbarch *gdbarch, int long_long_bit)
static CORE_ADDR sh64_frame_base_address(struct frame_info *this_frame, void **this_cache)
static CORE_ADDR look_for_args_moves(struct gdbarch *gdbarch, CORE_ADDR start_pc, int media_mode)
#define MSYMBOL_IS_SPECIAL(msym)
static int sh64_dr_reg_base_num(struct gdbarch *gdbarch, int dr_regnum)
void print_spaces_filtered(int n, struct ui_file *stream)
int core_addr_lessthan(CORE_ADDR lhs, CORE_ADDR rhs)
void set_gdbarch_pseudo_register_read(struct gdbarch *gdbarch, gdbarch_pseudo_register_read_ftype pseudo_register_read)
const struct language_defn * current_language
struct type * builtin_double
struct bound_minimal_symbol lookup_minimal_symbol_by_pc(CORE_ADDR pc)
int deprecated_frame_register_read(struct frame_info *frame, int regnum, gdb_byte *myaddr)
int gdbarch_fp0_regnum(struct gdbarch *gdbarch)
static CORE_ADDR sh64_frame_align(struct gdbarch *ignore, CORE_ADDR sp)
#define TYPE_CODE(thistype)
enum register_status regcache_raw_read(struct regcache *regcache, int regnum, gdb_byte *buf)
struct value * frame_unwind_got_register(struct frame_info *frame, int regnum, int new_regnum)
void regcache_cooked_write_unsigned(struct regcache *regcache, int regnum, ULONGEST val)
#define IS_ISA32_ADDR(addr)
void set_gdbarch_int_bit(struct gdbarch *gdbarch, int int_bit)
struct minimal_symbol * minsym
static int sh64_fv_reg_base_num(struct gdbarch *gdbarch, int fv_regnum)
#define IS_STL_R18_R15(x)
static struct sh64_frame_cache * sh64_frame_cache(struct frame_info *this_frame, void **this_cache)
void set_gdbarch_num_pseudo_regs(struct gdbarch *gdbarch, int num_pseudo_regs)
static void sh64_do_pseudo_register(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum)
void dwarf2_append_unwinders(struct gdbarch *gdbarch)
enum register_status regcache_cooked_read(struct regcache *regcache, int regnum, gdb_byte *buf)
static void sh64_do_register(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum)
static void sh64_frame_this_id(struct frame_info *this_frame, void **this_cache, struct frame_id *this_id)
static int pc_is_isa32(bfd_vma memaddr)
static CORE_ADDR sh64_unwind_pc(struct gdbarch *gdbarch, struct frame_info *next_frame)
#define IS_ADDI_SP_MEDIA(x)
static struct value * sh64_frame_prev_register(struct frame_info *this_frame, void **this_cache, int regnum)
enum unwind_stop_reason default_frame_unwind_stop_reason(struct frame_info *this_frame, void **this_cache)
static CORE_ADDR sh64_unwind_sp(struct gdbarch *gdbarch, struct frame_info *next_frame)
struct type * builtin_long_long
static int ignore(struct target_ops *ops, struct gdbarch *gdbarch, struct bp_target_info *bp_tgt)
int register_size(struct gdbarch *gdbarch, int regnum)
void set_gdbarch_long_double_bit(struct gdbarch *gdbarch, int long_double_bit)
struct type * value_type(const struct value *value)
void set_gdbarch_long_bit(struct gdbarch *gdbarch, int long_bit)
void set_gdbarch_return_value(struct gdbarch *gdbarch, gdbarch_return_value_ftype return_value)
int gdbarch_pc_regnum(struct gdbarch *gdbarch)
static void sh64_do_fp_register(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum)
static void sh64_compact_print_registers_info(struct gdbarch *gdbarch, struct ui_file *file, struct frame_info *frame, int regnum, int fpregs)
#define TYPE_LENGTH(thistype)
void set_gdbarch_ptr_bit(struct gdbarch *gdbarch, int ptr_bit)
#define IS_STQ_R18_R14(x)
void set_gdbarch_push_dummy_call(struct gdbarch *gdbarch, gdbarch_push_dummy_call_ftype push_dummy_call)
ULONGEST read_memory_unsigned_integer(CORE_ADDR memaddr, int len, enum bfd_endian byte_order)
void write_memory(CORE_ADDR memaddr, const bfd_byte *myaddr, ssize_t len)
void set_gdbarch_skip_prologue(struct gdbarch *gdbarch, gdbarch_skip_prologue_ftype skip_prologue)
static void sh64_store_return_value(struct type *type, struct regcache *regcache, const gdb_byte *valbuf)
#define IS_COMPACT_IND_ARG_MOV(x)
#define IS_COMPACT_ARG_MOV(x)
enum bfd_endian byte_order
void set_gdbarch_pc_regnum(struct gdbarch *gdbarch, int pc_regnum)
static const unsigned char * sh64_breakpoint_from_pc(struct gdbarch *gdbarch, CORE_ADDR *pcptr, int *lenptr)
void set_gdbarch_register_name(struct gdbarch *gdbarch, gdbarch_register_name_ftype register_name)
CORE_ADDR get_frame_func(struct frame_info *this_frame)
void val_print(struct type *type, const gdb_byte *valaddr, int embedded_offset, CORE_ADDR address, struct ui_file *stream, int recurse, const struct value *val, const struct value_print_options *options, const struct language_defn *language)
void error(const char *fmt,...)
struct gdbarch * gdbarch_alloc(const struct gdbarch_info *info, struct gdbarch_tdep *tdep)
#define NUM_PSEUDO_REGS_SH_COMPACT
void set_gdbarch_inner_than(struct gdbarch *gdbarch, gdbarch_inner_than_ftype inner_than)
void store_typed_floating(void *addr, const struct type *type, DOUBLEST val)
struct gdbarch * get_frame_arch(struct frame_info *this_frame)
static struct sh64_frame_cache * sh64_alloc_frame_cache(void)
static int sh64_fpp_reg_base_num(struct gdbarch *gdbarch, int fpp_regnum)
void regcache_cooked_write(struct regcache *regcache, int regnum, const gdb_byte *buf)
void set_gdbarch_print_insn(struct gdbarch *gdbarch, gdbarch_print_insn_ftype print_insn)
struct type * builtin_float
void print_hex_chars(struct ui_file *stream, const gdb_byte *valaddr, unsigned len, enum bfd_endian byte_order)
struct type * builtin_int
void regcache_raw_write(struct regcache *regcache, int regnum, const gdb_byte *buf)
const ULONGEST const LONGEST len