/* Target-dependent code for the CSKY architecture, for GDB.
- Copyright (C) 2010-2020 Free Software Foundation, Inc.
+ Copyright (C) 2010-2021 Free Software Foundation, Inc.
Contributed by C-SKY Microsystems and Mentor Graphics.
int framereg;
/* Saved register offsets. */
- struct trad_frame_saved_reg *saved_regs;
+ trad_frame_saved_reg *saved_regs;
};
/* Do prologue analysis, returning the PC of the first instruction
{
if (register_offsets[rn] >= 0)
{
- this_cache->saved_regs[rn].addr
- = this_cache->prev_sp - register_offsets[rn];
+ this_cache->saved_regs[rn].set_addr (this_cache->prev_sp
+ - register_offsets[rn]);
if (csky_debug)
{
CORE_ADDR rn_value = read_memory_unsigned_integer (
- this_cache->saved_regs[rn].addr, 4, byte_order);
+ this_cache->saved_regs[rn].addr (), 4, byte_order);
fprintf_unfiltered (gdb_stdlog, "Saved register %s "
"stored at 0x%08lx, value=0x%08lx\n",
csky_register_names[rn],
(unsigned long)
- this_cache->saved_regs[rn].addr,
+ this_cache->saved_regs[rn].addr (),
(unsigned long) rn_value);
}
}
func_end, this_frame, cache, lr_type);
/* gdbarch_sp_regnum contains the value and not the address. */
- trad_frame_set_value (cache->saved_regs, sp_regnum, cache->prev_sp);
+ cache->saved_regs[sp_regnum].set_value (cache->prev_sp);
return cache;
}
unwinder. */
static const struct frame_unwind csky_unwind_cache = {
+ "cski prologue",
NORMAL_FRAME,
default_frame_unwind_stop_reason,
csky_frame_this_id,
prev_regnum);
}
-struct frame_unwind csky_stub_unwind = {
+static frame_unwind csky_stub_unwind = {
+ "csky stub",
NORMAL_FRAME,
default_frame_unwind_stop_reason,
csky_stub_this_id,