+2014-05-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
+
+ * sparc-linux-nat.c (supply_gregset, supply_fpregset)
+ (fill_gregset, fill_fpregset, _initialize_sparc_linux_nat): Rename
+ register maps ("regmaps") from "*regset" to "*regmap". Do this
+ for all regmap types and variables.
+ * sparc-linux-tdep.c (sparc32_linux_step_trap)
+ (sparc32_linux_supply_core_gregset)
+ (sparc32_linux_collect_core_gregset)
+ (sparc32_linux_supply_core_fpregset)
+ (sparc32_linux_collect_core_fpregset): Likewise.
+ * sparc-nat.c (sparc_gregset, sparc_fpregset): Rename to...
+ (sparc_gregmap, sparc_fpregmap): ... these.
+ (sparc_supply_gregset, sparc_collect_gregset)
+ (sparc_supply_fpregset, sparc_collect_fpregset): Likewise.
+ (sparc_fetch_inferior_registers, sparc_store_inferior_registers)
+ (_initialize_sparc_nat): Rename regmaps.
+ * sparc-nat.h (sparc_gregset, sparc_fpregset): Rename to...
+ (sparc_gregmap, sparc_fpregmap): ... these.
+ (sparc_supply_gregset, sparc_collect_gregset)
+ (sparc_supply_fpregset, sparc_collect_fpregset): Likewise.
+ * sparc-sol2-nat.c (sparc_sol2_gregset, sparc_sol2_fpregset):
+ Rename macros to...
+ (sparc_sol2_gregmap, sparc_sol2_fpregmap): ... these.
+ (supply_gregset, supply_fpregset, fill_gregset, fill_fpregset):
+ Likewise.
+ * sparc-sol2-tdep.c (sparc32_sol2_gregset, sparc32_sol2_fpregset):
+ Rename to...
+ (sparc32_sol2_gregmap, sparc32_sol2_fpregmap): ... these.
+ * sparc-tdep.c (sparc32_supply_gregset, sparc32_collect_gregset)
+ (sparc32_supply_fpregset, sparc32_collect_fpregset): Rename
+ regmaps.
+ (sparc32_sunos4_gregset, sparc32_sunos4_fpregset)
+ (sparc32_bsd_fpregset): Rename to...
+ (sparc32_sunos4_gregmap, sparc32_sunos4_fpregmap)
+ (sparc32_bsd_fpregmap): ... these.
+ * sparc-tdep.h (struct sparc_gregset, struct sparc_fpregset)
+ (sparc32_sunos4_gregset, sparc32_sunos4_fpregset)
+ (sparc32_bsd_fpregset, sparc32_sol2_gregset)
+ (sparc32_sol2_fpregset, sparc32nbsd_gregset): Rename to...
+ (struct sparc_gregmap, struct sparc_fpregmap)
+ (sparc32_sunos4_gregmap, sparc32_sunos4_fpregmap)
+ (sparc32_bsd_fpregmap, sparc32_sol2_gregmap)
+ (sparc32_sol2_fpregmap, sparc32nbsd_gregmap): ... these.
+ (sparc32_supply_regset, sparc32_collect_gregset)
+ (sparc32_supply_fpregset, sparc32_collect_fpregset): Adjust
+ prototypes.
+ * sparc64-linux-nat.c (sparc64_linux_ptrace_gregset): Rename to...
+ (sparc64_linux_ptrace_gregmap): ... this.
+ (supply_gregset, supply_fpregset, fill_gregset, fill_fpregset)
+ (_initialize_sparc64_linux_nat): Rename regmaps.
+ * sparc64-linux-tdep.c (sparc64_linux_core_gregset): Rename to...
+ (sparc64_linux_core_gregmap): ... this.
+ (sparc64_linux_supply_core_gregset)
+ (sparc64_linux_collect_core_gregset)
+ (sparc64_linux_supply_core_fpregset)
+ (sparc64_linux_collect_core_fpregset): Rename regmaps.
+ * sparc64-sol2-tdep.c (sparc64_sol2_gregset)
+ (sparc64_sol2_fpregset): Rename to...
+ (sparc64_sol2_gregmap, sparc64_sol2_fpregmap): ... these.
+ * sparc64-tdep.c (sparc64_supply_gregset, sparc64_collect_gregset)
+ (sparc64_supply_fpregset, sparc64_collect_fpregset): Rename
+ regmaps.
+ * sparc64-tdep.h (struct sparc_gregset, sparc64_sol2_gregset)
+ (sparc64_sol2_fpregset, sparc64fbsd_gregset, sparc64nbsd_gregset)
+ (sparc64_bsd_fpregset): Rename to...
+ (struct sparc_gregmap, sparc64_sol2_gregmap)
+ (sparc64_sol2_fpregmap, sparc64fbsd_gregmap, sparc64nbsd_gregmap)
+ (sparc64_bsd_fpregmap): ... these.
+ (sparc64_supply_gregset, sparc64_collect_gregset)
+ (sparc64_supply_fpregset, sparc64_collect_fpregset): Adjust
+ prototypes.
+ * sparc64fbsd-nat.c (_initialize_sparc64fbsd_nat): Rename regmaps.
+ * sparc64fbsd-tdep.c (sparc64fbsd_gregset): Rename to...
+ (sparc64fbsd_gregmap): ... this.
+ (sparc64fbsd_supply_gregset, sparc64fbsd_collect_gregset)
+ (sparc64fbsd_supply_fpregset, sparc64fbsd_collect_fpregset):
+ Rename regmaps.
+ * sparc64nbsd-nat.c (sparc64nbsd_supply_gregset)
+ (sparc64nbsd_collect_gregset, sparc64nbsd_supply_fpregset)
+ (sparc64nbsd_collect_fpregset): Likewise.
+ * sparc64nbsd-tdep.c (sparc64nbsd_gregset): Rename to...
+ (sparc64nbsd_gregmap): ... this.
+ (sparc64nbsd_supply_gregset, sparc64nbsd_supply_fpregset): Rename
+ regmaps.
+ * sparc64obsd-nat.c (_initialize_sparc64obsd_nat): Likewise.
+ * sparc64obsd-tdep.c (sparc64obsd_gregset): Rename to...
+ (sparc64obsd_gregmap): ... this.
+ (sparc64obsd_supply_gregset, sparc64obsd_supply_fpregset): Rename
+ regmaps.
+ * sparcnbsd-nat.c (_initialize_sparcnbsd_nat): Likewise.
+ * sparcnbsd-tdep.c (sparc32nbsd_gregset): Rename to...
+ (sparc32nbsd_gregmap): ... this.
+ (sparc32nbsd_supply_gregset, sparc32nbsd_supply_fpregset): Rename
+ regmaps.
+
2014-05-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
* score-tdep.c (score7_linux_gregset): New static regset
void
supply_gregset (struct regcache *regcache, const prgregset_t *gregs)
{
- sparc32_supply_gregset (sparc_gregset, regcache, -1, gregs);
+ sparc32_supply_gregset (sparc_gregmap, regcache, -1, gregs);
}
void
supply_fpregset (struct regcache *regcache, const prfpregset_t *fpregs)
{
- sparc32_supply_fpregset (sparc_fpregset, regcache, -1, fpregs);
+ sparc32_supply_fpregset (sparc_fpregmap, regcache, -1, fpregs);
}
void
fill_gregset (const struct regcache *regcache, prgregset_t *gregs, int regnum)
{
- sparc32_collect_gregset (sparc_gregset, regcache, regnum, gregs);
+ sparc32_collect_gregset (sparc_gregmap, regcache, regnum, gregs);
}
void
fill_fpregset (const struct regcache *regcache,
prfpregset_t *fpregs, int regnum)
{
- sparc32_collect_fpregset (sparc_fpregset, regcache, regnum, fpregs);
+ sparc32_collect_fpregset (sparc_fpregmap, regcache, regnum, fpregs);
}
void _initialize_sparc_linux_nat (void);
/* Fill in the generic GNU/Linux methods. */
t = linux_target ();
- sparc_fpregset = &sparc32_bsd_fpregset;
+ sparc_fpregmap = &sparc32_bsd_fpregmap;
/* Add our register access methods. */
t->to_fetch_registers = sparc_fetch_inferior_registers;
}
\f
-const struct sparc_gregset sparc32_linux_core_gregset =
+const struct sparc_gregmap sparc32_linux_core_gregmap =
{
32 * 4, /* %psr */
33 * 4, /* %pc */
struct regcache *regcache,
int regnum, const void *gregs, size_t len)
{
- sparc32_supply_gregset (&sparc32_linux_core_gregset,
+ sparc32_supply_gregset (&sparc32_linux_core_gregmap,
regcache, regnum, gregs);
}
const struct regcache *regcache,
int regnum, void *gregs, size_t len)
{
- sparc32_collect_gregset (&sparc32_linux_core_gregset,
+ sparc32_collect_gregset (&sparc32_linux_core_gregmap,
regcache, regnum, gregs);
}
struct regcache *regcache,
int regnum, const void *fpregs, size_t len)
{
- sparc32_supply_fpregset (&sparc32_bsd_fpregset, regcache, regnum, fpregs);
+ sparc32_supply_fpregset (&sparc32_bsd_fpregmap, regcache, regnum, fpregs);
}
static void
const struct regcache *regcache,
int regnum, void *fpregs, size_t len)
{
- sparc32_collect_fpregset (&sparc32_bsd_fpregset, regcache, regnum, fpregs);
+ sparc32_collect_fpregset (&sparc32_bsd_fpregmap, regcache, regnum, fpregs);
}
/* Set the program counter for process PTID to PC. */
#endif
/* Register set description. */
-const struct sparc_gregset *sparc_gregset;
-const struct sparc_fpregset *sparc_fpregset;
-void (*sparc_supply_gregset) (const struct sparc_gregset *,
+const struct sparc_gregmap *sparc_gregmap;
+const struct sparc_fpregmap *sparc_fpregmap;
+void (*sparc_supply_gregset) (const struct sparc_gregmap *,
struct regcache *, int , const void *);
-void (*sparc_collect_gregset) (const struct sparc_gregset *,
+void (*sparc_collect_gregset) (const struct sparc_gregmap *,
const struct regcache *, int, void *);
-void (*sparc_supply_fpregset) (const struct sparc_fpregset *,
+void (*sparc_supply_fpregset) (const struct sparc_fpregmap *,
struct regcache *, int , const void *);
-void (*sparc_collect_fpregset) (const struct sparc_fpregset *,
+void (*sparc_collect_fpregset) (const struct sparc_fpregmap *,
const struct regcache *, int , void *);
int (*sparc_gregset_supplies_p) (struct gdbarch *, int);
int (*sparc_fpregset_supplies_p) (struct gdbarch *, int);
if (ptrace (PTRACE_GETREGS, pid, (PTRACE_TYPE_ARG3) ®s, 0) == -1)
perror_with_name (_("Couldn't get registers"));
- sparc_supply_gregset (sparc_gregset, regcache, -1, ®s);
+ sparc_supply_gregset (sparc_gregmap, regcache, -1, ®s);
if (regnum != -1)
return;
}
if (ptrace (PTRACE_GETFPREGS, pid, (PTRACE_TYPE_ARG3) &fpregs, 0) == -1)
perror_with_name (_("Couldn't get floating point status"));
- sparc_supply_fpregset (sparc_fpregset, regcache, -1, &fpregs);
+ sparc_supply_fpregset (sparc_fpregmap, regcache, -1, &fpregs);
}
}
if (ptrace (PTRACE_GETREGS, pid, (PTRACE_TYPE_ARG3) ®s, 0) == -1)
perror_with_name (_("Couldn't get registers"));
- sparc_collect_gregset (sparc_gregset, regcache, regnum, ®s);
+ sparc_collect_gregset (sparc_gregmap, regcache, regnum, ®s);
if (ptrace (PTRACE_SETREGS, pid, (PTRACE_TYPE_ARG3) ®s, 0) == -1)
perror_with_name (_("Couldn't write registers"));
perror_with_name (_("Couldn't get floating-point registers"));
memcpy (&saved_fpregs, &fpregs, sizeof (fpregs));
- sparc_collect_fpregset (sparc_fpregset, regcache, regnum, &fpregs);
+ sparc_collect_fpregset (sparc_fpregmap, regcache, regnum, &fpregs);
/* Writing the floating-point registers will fail on NetBSD with
EINVAL if the inferior process doesn't have an FPU state
_initialize_sparc_nat (void)
{
/* Deafult to using SunOS 4 register sets. */
- if (sparc_gregset == NULL)
- sparc_gregset = &sparc32_sunos4_gregset;
- if (sparc_fpregset == NULL)
- sparc_fpregset = &sparc32_sunos4_fpregset;
+ if (sparc_gregmap == NULL)
+ sparc_gregmap = &sparc32_sunos4_gregmap;
+ if (sparc_fpregmap == NULL)
+ sparc_fpregmap = &sparc32_sunos4_fpregmap;
if (sparc_supply_gregset == NULL)
sparc_supply_gregset = sparc32_supply_gregset;
if (sparc_collect_gregset == NULL)
#ifndef SPARC_NAT_H
#define SPARC_NAT_H 1
-struct sparc_gregset;
-struct sparc_fpregset;
+struct sparc_gregmap;
+struct sparc_fpregmap;
-extern const struct sparc_gregset *sparc_gregset;
-extern const struct sparc_fpregset *sparc_fpregset;
-extern void (*sparc_supply_gregset) (const struct sparc_gregset *,
+extern const struct sparc_gregmap *sparc_gregmap;
+extern const struct sparc_fpregmap *sparc_fpregmap;
+extern void (*sparc_supply_gregset) (const struct sparc_gregmap *,
struct regcache *, int , const void *);
-extern void (*sparc_collect_gregset) (const struct sparc_gregset *,
+extern void (*sparc_collect_gregset) (const struct sparc_gregmap *,
const struct regcache *, int, void *);
-extern void (*sparc_supply_fpregset) (const struct sparc_fpregset *,
+extern void (*sparc_supply_fpregset) (const struct sparc_fpregmap *,
struct regcache *, int , const void *);
-extern void (*sparc_collect_fpregset) (const struct sparc_fpregset *,
+extern void (*sparc_collect_fpregset) (const struct sparc_fpregmap *,
const struct regcache *, int , void *);
extern int (*sparc_gregset_supplies_p) (struct gdbarch *gdbarch, int);
extern int (*sparc_fpregset_supplies_p) (struct gdbarch *gdbarch, int);
#define sparc_collect_gregset sparc64_collect_gregset
#define sparc_collect_fpregset sparc64_collect_fpregset
-#define sparc_sol2_gregset sparc64_sol2_gregset
-#define sparc_sol2_fpregset sparc64_sol2_fpregset
+#define sparc_sol2_gregmap sparc64_sol2_gregmap
+#define sparc_sol2_fpregmap sparc64_sol2_fpregmap
#else
#define sparc_collect_gregset sparc32_collect_gregset
#define sparc_collect_fpregset sparc32_collect_fpregset
-#define sparc_sol2_gregset sparc32_sol2_gregset
-#define sparc_sol2_fpregset sparc32_sol2_fpregset
+#define sparc_sol2_gregmap sparc32_sol2_gregmap
+#define sparc_sol2_fpregmap sparc32_sol2_fpregmap
#endif
void
supply_gregset (struct regcache *regcache, const prgregset_t *gregs)
{
- sparc_supply_gregset (&sparc_sol2_gregset, regcache, -1, gregs);
+ sparc_supply_gregset (&sparc_sol2_gregmap, regcache, -1, gregs);
}
void
supply_fpregset (struct regcache *regcache, const prfpregset_t *fpregs)
{
- sparc_supply_fpregset (&sparc_sol2_fpregset, regcache, -1, fpregs);
+ sparc_supply_fpregset (&sparc_sol2_fpregmap, regcache, -1, fpregs);
}
void
fill_gregset (const struct regcache *regcache, prgregset_t *gregs, int regnum)
{
- sparc_collect_gregset (&sparc_sol2_gregset, regcache, regnum, gregs);
+ sparc_collect_gregset (&sparc_sol2_gregmap, regcache, regnum, gregs);
}
void
fill_fpregset (const struct regcache *regcache,
prfpregset_t *fpregs, int regnum)
{
- sparc_collect_fpregset (&sparc_sol2_fpregset, regcache, regnum, fpregs);
+ sparc_collect_fpregset (&sparc_sol2_fpregmap, regcache, regnum, fpregs);
}
/* Provide a prototype to silence -Wmissing-prototypes. */
#include "solib-svr4.h"
/* From <sys/regset.h>. */
-const struct sparc_gregset sparc32_sol2_gregset =
+const struct sparc_gregmap sparc32_sol2_gregmap =
{
32 * 4, /* %psr */
33 * 4, /* %pc */
16 * 4, /* %l0 */
};
-const struct sparc_fpregset sparc32_sol2_fpregset =
+const struct sparc_fpregmap sparc32_sol2_fpregmap =
{
0 * 4, /* %f0 */
33 * 4, /* %fsr */
/* Helper functions for dealing with register sets. */
void
-sparc32_supply_gregset (const struct sparc_gregset *gregset,
+sparc32_supply_gregset (const struct sparc_gregmap *gregmap,
struct regcache *regcache,
int regnum, const void *gregs)
{
if (regnum == SPARC32_PSR_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_PSR_REGNUM,
- regs + gregset->r_psr_offset);
+ regs + gregmap->r_psr_offset);
if (regnum == SPARC32_PC_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_PC_REGNUM,
- regs + gregset->r_pc_offset);
+ regs + gregmap->r_pc_offset);
if (regnum == SPARC32_NPC_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_NPC_REGNUM,
- regs + gregset->r_npc_offset);
+ regs + gregmap->r_npc_offset);
if (regnum == SPARC32_Y_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_Y_REGNUM,
- regs + gregset->r_y_offset);
+ regs + gregmap->r_y_offset);
if (regnum == SPARC_G0_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC_G0_REGNUM, &zero);
if ((regnum >= SPARC_G1_REGNUM && regnum <= SPARC_O7_REGNUM) || regnum == -1)
{
- int offset = gregset->r_g1_offset;
+ int offset = gregmap->r_g1_offset;
for (i = SPARC_G1_REGNUM; i <= SPARC_O7_REGNUM; i++)
{
{
/* Not all of the register set variants include Locals and
Inputs. For those that don't, we read them off the stack. */
- if (gregset->r_l0_offset == -1)
+ if (gregmap->r_l0_offset == -1)
{
ULONGEST sp;
}
else
{
- int offset = gregset->r_l0_offset;
+ int offset = gregmap->r_l0_offset;
for (i = SPARC_L0_REGNUM; i <= SPARC_I7_REGNUM; i++)
{
}
void
-sparc32_collect_gregset (const struct sparc_gregset *gregset,
+sparc32_collect_gregset (const struct sparc_gregmap *gregmap,
const struct regcache *regcache,
int regnum, void *gregs)
{
if (regnum == SPARC32_PSR_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_PSR_REGNUM,
- regs + gregset->r_psr_offset);
+ regs + gregmap->r_psr_offset);
if (regnum == SPARC32_PC_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_PC_REGNUM,
- regs + gregset->r_pc_offset);
+ regs + gregmap->r_pc_offset);
if (regnum == SPARC32_NPC_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_NPC_REGNUM,
- regs + gregset->r_npc_offset);
+ regs + gregmap->r_npc_offset);
if (regnum == SPARC32_Y_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_Y_REGNUM,
- regs + gregset->r_y_offset);
+ regs + gregmap->r_y_offset);
if ((regnum >= SPARC_G1_REGNUM && regnum <= SPARC_O7_REGNUM) || regnum == -1)
{
- int offset = gregset->r_g1_offset;
+ int offset = gregmap->r_g1_offset;
/* %g0 is always zero. */
for (i = SPARC_G1_REGNUM; i <= SPARC_O7_REGNUM; i++)
{
/* Not all of the register set variants include Locals and
Inputs. For those that don't, we read them off the stack. */
- if (gregset->r_l0_offset != -1)
+ if (gregmap->r_l0_offset != -1)
{
- int offset = gregset->r_l0_offset;
+ int offset = gregmap->r_l0_offset;
for (i = SPARC_L0_REGNUM; i <= SPARC_I7_REGNUM; i++)
{
}
void
-sparc32_supply_fpregset (const struct sparc_fpregset *fpregset,
+sparc32_supply_fpregset (const struct sparc_fpregmap *fpregmap,
struct regcache *regcache,
int regnum, const void *fpregs)
{
{
if (regnum == (SPARC_F0_REGNUM + i) || regnum == -1)
regcache_raw_supply (regcache, SPARC_F0_REGNUM + i,
- regs + fpregset->r_f0_offset + (i * 4));
+ regs + fpregmap->r_f0_offset + (i * 4));
}
if (regnum == SPARC32_FSR_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_FSR_REGNUM,
- regs + fpregset->r_fsr_offset);
+ regs + fpregmap->r_fsr_offset);
}
void
-sparc32_collect_fpregset (const struct sparc_fpregset *fpregset,
+sparc32_collect_fpregset (const struct sparc_fpregmap *fpregmap,
const struct regcache *regcache,
int regnum, void *fpregs)
{
{
if (regnum == (SPARC_F0_REGNUM + i) || regnum == -1)
regcache_raw_collect (regcache, SPARC_F0_REGNUM + i,
- regs + fpregset->r_f0_offset + (i * 4));
+ regs + fpregmap->r_f0_offset + (i * 4));
}
if (regnum == SPARC32_FSR_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_FSR_REGNUM,
- regs + fpregset->r_fsr_offset);
+ regs + fpregmap->r_fsr_offset);
}
\f
/* SunOS 4. */
/* From <machine/reg.h>. */
-const struct sparc_gregset sparc32_sunos4_gregset =
+const struct sparc_gregmap sparc32_sunos4_gregmap =
{
0 * 4, /* %psr */
1 * 4, /* %pc */
-1 /* %l0 */
};
-const struct sparc_fpregset sparc32_sunos4_fpregset =
+const struct sparc_fpregmap sparc32_sunos4_fpregmap =
{
0 * 4, /* %f0 */
33 * 4, /* %fsr */
};
-const struct sparc_fpregset sparc32_bsd_fpregset =
+const struct sparc_fpregmap sparc32_bsd_fpregmap =
{
0 * 4, /* %f0 */
32 * 4, /* %fsr */
/* Register offsets for the general-purpose register set. */
-struct sparc_gregset
+struct sparc_gregmap
{
int r_psr_offset;
int r_pc_offset;
int r_y_size;
};
-struct sparc_fpregset
+struct sparc_fpregmap
{
int r_f0_offset;
int r_fsr_offset;
CORE_ADDR sp, int regnum);
/* Register offsets for SunOS 4. */
-extern const struct sparc_gregset sparc32_sunos4_gregset;
-extern const struct sparc_fpregset sparc32_sunos4_fpregset;
-extern const struct sparc_fpregset sparc32_bsd_fpregset;
+extern const struct sparc_gregmap sparc32_sunos4_gregmap;
+extern const struct sparc_fpregmap sparc32_sunos4_fpregmap;
+extern const struct sparc_fpregmap sparc32_bsd_fpregmap;
-extern void sparc32_supply_gregset (const struct sparc_gregset *gregset,
+extern void sparc32_supply_gregset (const struct sparc_gregmap *gregmap,
struct regcache *regcache,
int regnum, const void *gregs);
-extern void sparc32_collect_gregset (const struct sparc_gregset *gregset,
+extern void sparc32_collect_gregset (const struct sparc_gregmap *gregmap,
const struct regcache *regcache,
int regnum, void *gregs);
-extern void sparc32_supply_fpregset (const struct sparc_fpregset *fpregset,
+extern void sparc32_supply_fpregset (const struct sparc_fpregmap *fpregmap,
struct regcache *regcache,
int regnum, const void *fpregs);
-extern void sparc32_collect_fpregset (const struct sparc_fpregset *fpregset,
+extern void sparc32_collect_fpregset (const struct sparc_fpregmap *fpregmap,
const struct regcache *regcache,
int regnum, void *fpregs);
/* Functions and variables exported from sparc-sol2-tdep.c. */
/* Register offsets for Solaris 2. */
-extern const struct sparc_gregset sparc32_sol2_gregset;
-extern const struct sparc_fpregset sparc32_sol2_fpregset;
+extern const struct sparc_gregmap sparc32_sol2_gregmap;
+extern const struct sparc_fpregmap sparc32_sol2_fpregmap;
extern int sparc_sol2_pc_in_sigtramp (CORE_ADDR pc, const char *name);
/* Functions and variables exported from sparcnbsd-tdep.c. */
/* Register offsets for NetBSD. */
-extern const struct sparc_gregset sparc32nbsd_gregset;
+extern const struct sparc_gregmap sparc32nbsd_gregmap;
/* Return the address of a system call's alternative return
address. */
#include "target.h"
#include "linux-nat.h"
-static const struct sparc_gregset sparc64_linux_ptrace_gregset =
+static const struct sparc_gregmap sparc64_linux_ptrace_gregmap =
{
16 * 8, /* "tstate" */
17 * 8, /* %pc */
void
supply_gregset (struct regcache *regcache, const prgregset_t *gregs)
{
- sparc64_supply_gregset (sparc_gregset, regcache, -1, gregs);
+ sparc64_supply_gregset (sparc_gregmap, regcache, -1, gregs);
}
void
supply_fpregset (struct regcache *regcache, const prfpregset_t *fpregs)
{
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, -1, fpregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, -1, fpregs);
}
void
fill_gregset (const struct regcache *regcache, prgregset_t *gregs, int regnum)
{
- sparc64_collect_gregset (sparc_gregset, regcache, regnum, gregs);
+ sparc64_collect_gregset (sparc_gregmap, regcache, regnum, gregs);
}
void
fill_fpregset (const struct regcache *regcache,
prfpregset_t *fpregs, int regnum)
{
- sparc64_collect_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_collect_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
/* Provide a prototype to silence -Wmissing-prototypes. */
/* Fill in the generic GNU/Linux methods. */
t = linux_target ();
- sparc_fpregset = &sparc64_bsd_fpregset;
+ sparc_fpregmap = &sparc64_bsd_fpregmap;
/* Add our register access methods. */
t->to_fetch_registers = sparc_fetch_inferior_registers;
/* Register the target. */
linux_nat_add_target (t);
- sparc_gregset = &sparc64_linux_ptrace_gregset;
+ sparc_gregmap = &sparc64_linux_ptrace_gregmap;
}
}
\f
-const struct sparc_gregset sparc64_linux_core_gregset =
+const struct sparc_gregmap sparc64_linux_core_gregmap =
{
32 * 8, /* %tstate */
33 * 8, /* %tpc */
struct regcache *regcache,
int regnum, const void *gregs, size_t len)
{
- sparc64_supply_gregset (&sparc64_linux_core_gregset,
+ sparc64_supply_gregset (&sparc64_linux_core_gregmap,
regcache, regnum, gregs);
}
const struct regcache *regcache,
int regnum, void *gregs, size_t len)
{
- sparc64_collect_gregset (&sparc64_linux_core_gregset,
+ sparc64_collect_gregset (&sparc64_linux_core_gregmap,
regcache, regnum, gregs);
}
struct regcache *regcache,
int regnum, const void *fpregs, size_t len)
{
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
static void
const struct regcache *regcache,
int regnum, void *fpregs, size_t len)
{
- sparc64_collect_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_collect_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
/* Set the program counter for process PTID to PC. */
#include "solib-svr4.h"
/* From <sys/regset.h>. */
-const struct sparc_gregset sparc64_sol2_gregset =
+const struct sparc_gregmap sparc64_sol2_gregmap =
{
32 * 8, /* "tstate" */
33 * 8, /* %pc */
8 /* sizeof (%y) */
};
-const struct sparc_fpregset sparc64_sol2_fpregset =
+const struct sparc_fpregmap sparc64_sol2_fpregmap =
{
0 * 8, /* %f0 */
33 * 8, /* %fsr */
#define PSR_XCC 0x000f0000
void
-sparc64_supply_gregset (const struct sparc_gregset *gregset,
+sparc64_supply_gregset (const struct sparc_gregmap *gregmap,
struct regcache *regcache,
int regnum, const void *gregs)
{
{
if (regnum == SPARC32_PSR_REGNUM || regnum == -1)
{
- int offset = gregset->r_tstate_offset;
+ int offset = gregmap->r_tstate_offset;
ULONGEST tstate, psr;
gdb_byte buf[4];
if (regnum == SPARC32_PC_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_PC_REGNUM,
- regs + gregset->r_pc_offset + 4);
+ regs + gregmap->r_pc_offset + 4);
if (regnum == SPARC32_NPC_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_NPC_REGNUM,
- regs + gregset->r_npc_offset + 4);
+ regs + gregmap->r_npc_offset + 4);
if (regnum == SPARC32_Y_REGNUM || regnum == -1)
{
- int offset = gregset->r_y_offset + 8 - gregset->r_y_size;
+ int offset = gregmap->r_y_offset + 8 - gregmap->r_y_size;
regcache_raw_supply (regcache, SPARC32_Y_REGNUM, regs + offset);
}
}
{
if (regnum == SPARC64_STATE_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC64_STATE_REGNUM,
- regs + gregset->r_tstate_offset);
+ regs + gregmap->r_tstate_offset);
if (regnum == SPARC64_PC_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC64_PC_REGNUM,
- regs + gregset->r_pc_offset);
+ regs + gregmap->r_pc_offset);
if (regnum == SPARC64_NPC_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC64_NPC_REGNUM,
- regs + gregset->r_npc_offset);
+ regs + gregmap->r_npc_offset);
if (regnum == SPARC64_Y_REGNUM || regnum == -1)
{
gdb_byte buf[8];
memset (buf, 0, 8);
- memcpy (buf + 8 - gregset->r_y_size,
- regs + gregset->r_y_offset, gregset->r_y_size);
+ memcpy (buf + 8 - gregmap->r_y_size,
+ regs + gregmap->r_y_offset, gregmap->r_y_size);
regcache_raw_supply (regcache, SPARC64_Y_REGNUM, buf);
}
if ((regnum == SPARC64_FPRS_REGNUM || regnum == -1)
- && gregset->r_fprs_offset != -1)
+ && gregmap->r_fprs_offset != -1)
regcache_raw_supply (regcache, SPARC64_FPRS_REGNUM,
- regs + gregset->r_fprs_offset);
+ regs + gregmap->r_fprs_offset);
}
if (regnum == SPARC_G0_REGNUM || regnum == -1)
if ((regnum >= SPARC_G1_REGNUM && regnum <= SPARC_O7_REGNUM) || regnum == -1)
{
- int offset = gregset->r_g1_offset;
+ int offset = gregmap->r_g1_offset;
if (sparc32)
offset += 4;
{
/* Not all of the register set variants include Locals and
Inputs. For those that don't, we read them off the stack. */
- if (gregset->r_l0_offset == -1)
+ if (gregmap->r_l0_offset == -1)
{
ULONGEST sp;
}
else
{
- int offset = gregset->r_l0_offset;
+ int offset = gregmap->r_l0_offset;
if (sparc32)
offset += 4;
}
void
-sparc64_collect_gregset (const struct sparc_gregset *gregset,
+sparc64_collect_gregset (const struct sparc_gregmap *gregmap,
const struct regcache *regcache,
int regnum, void *gregs)
{
{
if (regnum == SPARC32_PSR_REGNUM || regnum == -1)
{
- int offset = gregset->r_tstate_offset;
+ int offset = gregmap->r_tstate_offset;
ULONGEST tstate, psr;
gdb_byte buf[8];
if (regnum == SPARC32_PC_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_PC_REGNUM,
- regs + gregset->r_pc_offset + 4);
+ regs + gregmap->r_pc_offset + 4);
if (regnum == SPARC32_NPC_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_NPC_REGNUM,
- regs + gregset->r_npc_offset + 4);
+ regs + gregmap->r_npc_offset + 4);
if (regnum == SPARC32_Y_REGNUM || regnum == -1)
{
- int offset = gregset->r_y_offset + 8 - gregset->r_y_size;
+ int offset = gregmap->r_y_offset + 8 - gregmap->r_y_size;
regcache_raw_collect (regcache, SPARC32_Y_REGNUM, regs + offset);
}
}
{
if (regnum == SPARC64_STATE_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC64_STATE_REGNUM,
- regs + gregset->r_tstate_offset);
+ regs + gregmap->r_tstate_offset);
if (regnum == SPARC64_PC_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC64_PC_REGNUM,
- regs + gregset->r_pc_offset);
+ regs + gregmap->r_pc_offset);
if (regnum == SPARC64_NPC_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC64_NPC_REGNUM,
- regs + gregset->r_npc_offset);
+ regs + gregmap->r_npc_offset);
if (regnum == SPARC64_Y_REGNUM || regnum == -1)
{
gdb_byte buf[8];
regcache_raw_collect (regcache, SPARC64_Y_REGNUM, buf);
- memcpy (regs + gregset->r_y_offset,
- buf + 8 - gregset->r_y_size, gregset->r_y_size);
+ memcpy (regs + gregmap->r_y_offset,
+ buf + 8 - gregmap->r_y_size, gregmap->r_y_size);
}
if ((regnum == SPARC64_FPRS_REGNUM || regnum == -1)
- && gregset->r_fprs_offset != -1)
+ && gregmap->r_fprs_offset != -1)
regcache_raw_collect (regcache, SPARC64_FPRS_REGNUM,
- regs + gregset->r_fprs_offset);
+ regs + gregmap->r_fprs_offset);
}
if ((regnum >= SPARC_G1_REGNUM && regnum <= SPARC_O7_REGNUM) || regnum == -1)
{
- int offset = gregset->r_g1_offset;
+ int offset = gregmap->r_g1_offset;
if (sparc32)
offset += 4;
{
/* Not all of the register set variants include Locals and
Inputs. For those that don't, we read them off the stack. */
- if (gregset->r_l0_offset != -1)
+ if (gregmap->r_l0_offset != -1)
{
- int offset = gregset->r_l0_offset;
+ int offset = gregmap->r_l0_offset;
if (sparc32)
offset += 4;
}
void
-sparc64_supply_fpregset (const struct sparc_fpregset *fpregset,
+sparc64_supply_fpregset (const struct sparc_fpregmap *fpregmap,
struct regcache *regcache,
int regnum, const void *fpregs)
{
{
if (regnum == (SPARC_F0_REGNUM + i) || regnum == -1)
regcache_raw_supply (regcache, SPARC_F0_REGNUM + i,
- regs + fpregset->r_f0_offset + (i * 4));
+ regs + fpregmap->r_f0_offset + (i * 4));
}
if (sparc32)
{
if (regnum == SPARC32_FSR_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC32_FSR_REGNUM,
- regs + fpregset->r_fsr_offset);
+ regs + fpregmap->r_fsr_offset);
}
else
{
{
if (regnum == (SPARC64_F32_REGNUM + i) || regnum == -1)
regcache_raw_supply (regcache, SPARC64_F32_REGNUM + i,
- (regs + fpregset->r_f0_offset
+ (regs + fpregmap->r_f0_offset
+ (32 * 4) + (i * 8)));
}
if (regnum == SPARC64_FSR_REGNUM || regnum == -1)
regcache_raw_supply (regcache, SPARC64_FSR_REGNUM,
- regs + fpregset->r_fsr_offset);
+ regs + fpregmap->r_fsr_offset);
}
}
void
-sparc64_collect_fpregset (const struct sparc_fpregset *fpregset,
+sparc64_collect_fpregset (const struct sparc_fpregmap *fpregmap,
const struct regcache *regcache,
int regnum, void *fpregs)
{
{
if (regnum == (SPARC_F0_REGNUM + i) || regnum == -1)
regcache_raw_collect (regcache, SPARC_F0_REGNUM + i,
- regs + fpregset->r_f0_offset + (i * 4));
+ regs + fpregmap->r_f0_offset + (i * 4));
}
if (sparc32)
{
if (regnum == SPARC32_FSR_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC32_FSR_REGNUM,
- regs + fpregset->r_fsr_offset);
+ regs + fpregmap->r_fsr_offset);
}
else
{
{
if (regnum == (SPARC64_F32_REGNUM + i) || regnum == -1)
regcache_raw_collect (regcache, SPARC64_F32_REGNUM + i,
- (regs + fpregset->r_f0_offset
+ (regs + fpregmap->r_f0_offset
+ (32 * 4) + (i * 8)));
}
if (regnum == SPARC64_FSR_REGNUM || regnum == -1)
regcache_raw_collect (regcache, SPARC64_FSR_REGNUM,
- regs + fpregset->r_fsr_offset);
+ regs + fpregmap->r_fsr_offset);
}
}
-const struct sparc_fpregset sparc64_bsd_fpregset =
+const struct sparc_fpregmap sparc64_bsd_fpregmap =
{
0 * 8, /* %f0 */
32 * 8, /* %fsr */
struct frame_info;
struct gdbarch;
struct regcache;
-struct sparc_gregset;
+struct sparc_gregmap;
struct trad_frame_saved_reg;
#include "sparc-tdep.h"
extern void sparc64_init_abi (struct gdbarch_info info,
struct gdbarch *gdbarch);
-extern void sparc64_supply_gregset (const struct sparc_gregset *gregset,
+extern void sparc64_supply_gregset (const struct sparc_gregmap *gregmap,
struct regcache *regcache,
int regnum, const void *gregs);
-extern void sparc64_collect_gregset (const struct sparc_gregset *gregset,
+extern void sparc64_collect_gregset (const struct sparc_gregmap *gregmap,
const struct regcache *regcache,
int regnum, void *gregs);
-extern void sparc64_supply_fpregset (const struct sparc_fpregset *fpregset,
+extern void sparc64_supply_fpregset (const struct sparc_fpregmap *fpregmap,
struct regcache *regcache,
int regnum, const void *fpregs);
-extern void sparc64_collect_fpregset (const struct sparc_fpregset *fpregset,
+extern void sparc64_collect_fpregset (const struct sparc_fpregmap *fpregmap,
const struct regcache *regcache,
int regnum, void *fpregs);
/* Functions and variables exported from sparc64-sol2-tdep.c. */
/* Register offsets for Solaris 2. */
-extern const struct sparc_gregset sparc64_sol2_gregset;
-extern const struct sparc_fpregset sparc64_sol2_fpregset;
+extern const struct sparc_gregmap sparc64_sol2_gregmap;
+extern const struct sparc_fpregmap sparc64_sol2_fpregmap;
extern void sparc64_sol2_init_abi (struct gdbarch_info info,
struct gdbarch *gdbarch);
/* Variables exported from sparc64fbsd-tdep.c. */
/* Register offsets for FreeBSD/sparc64. */
-extern const struct sparc_gregset sparc64fbsd_gregset;
+extern const struct sparc_gregmap sparc64fbsd_gregmap;
/* Functions and variables exported from sparc64nbsd-tdep.c. */
/* Register offsets for NetBSD/sparc64. */
-extern const struct sparc_gregset sparc64nbsd_gregset;
+extern const struct sparc_gregmap sparc64nbsd_gregmap;
extern struct trad_frame_saved_reg *
sparc64nbsd_sigcontext_saved_regs (CORE_ADDR sigcontext_addr,
struct frame_info *next_frame);
-extern const struct sparc_fpregset sparc64_bsd_fpregset;
+extern const struct sparc_fpregmap sparc64_bsd_fpregmap;
#endif /* sparc64-tdep.h */
t->to_make_corefile_notes = fbsd_make_corefile_notes;
add_target (t);
- sparc_gregset = &sparc64fbsd_gregset;
+ sparc_gregmap = &sparc64fbsd_gregmap;
/* Support debugging kernel virtual memory images. */
bsd_kvm_add_target (sparc64fbsd_kvm_supply_pcb);
#include "solib-svr4.h"
/* From <machine/reg.h>. */
-const struct sparc_gregset sparc64fbsd_gregset =
+const struct sparc_gregmap sparc64fbsd_gregmap =
{
26 * 8, /* "tstate" */
25 * 8, /* %pc */
struct regcache *regcache,
int regnum, const void *gregs, size_t len)
{
- sparc64_supply_gregset (&sparc64fbsd_gregset, regcache, regnum, gregs);
+ sparc64_supply_gregset (&sparc64fbsd_gregmap, regcache, regnum, gregs);
}
static void
const struct regcache *regcache,
int regnum, void *gregs, size_t len)
{
- sparc64_collect_gregset (&sparc64fbsd_gregset, regcache, regnum, gregs);
+ sparc64_collect_gregset (&sparc64fbsd_gregmap, regcache, regnum, gregs);
}
static void
struct regcache *regcache,
int regnum, const void *fpregs, size_t len)
{
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
static void
const struct regcache *regcache,
int regnum, void *fpregs, size_t len)
{
- sparc64_collect_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_collect_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
\f
traced process is 32-bit or 64-bit. */
static void
-sparc64nbsd_supply_gregset (const struct sparc_gregset *gregset,
+sparc64nbsd_supply_gregset (const struct sparc_gregmap *gregmap,
struct regcache *regcache,
int regnum, const void *gregs)
{
int sparc32 = (gdbarch_ptr_bit (get_regcache_arch (regcache)) == 32);
if (sparc32)
- sparc32_supply_gregset (&sparc32nbsd_gregset, regcache, regnum, gregs);
+ sparc32_supply_gregset (&sparc32nbsd_gregmap, regcache, regnum, gregs);
else
- sparc64_supply_gregset (&sparc64nbsd_gregset, regcache, regnum, gregs);
+ sparc64_supply_gregset (&sparc64nbsd_gregmap, regcache, regnum, gregs);
}
static void
-sparc64nbsd_collect_gregset (const struct sparc_gregset *gregset,
+sparc64nbsd_collect_gregset (const struct sparc_gregmap *gregmap,
const struct regcache *regcache,
int regnum, void *gregs)
{
int sparc32 = (gdbarch_ptr_bit (get_regcache_arch (regcache)) == 32);
if (sparc32)
- sparc32_collect_gregset (&sparc32nbsd_gregset, regcache, regnum, gregs);
+ sparc32_collect_gregset (&sparc32nbsd_gregmap, regcache, regnum, gregs);
else
- sparc64_collect_gregset (&sparc64nbsd_gregset, regcache, regnum, gregs);
+ sparc64_collect_gregset (&sparc64nbsd_gregmap, regcache, regnum, gregs);
}
static void
-sparc64nbsd_supply_fpregset (const struct sparc_fpregset *fpregset,
+sparc64nbsd_supply_fpregset (const struct sparc_fpregmap *fpregmap,
struct regcache *regcache,
int regnum, const void *fpregs)
{
int sparc32 = (gdbarch_ptr_bit (get_regcache_arch (regcache)) == 32);
if (sparc32)
- sparc32_supply_fpregset (&sparc32_bsd_fpregset, regcache, regnum, fpregs);
+ sparc32_supply_fpregset (&sparc32_bsd_fpregmap, regcache, regnum, fpregs);
else
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
static void
-sparc64nbsd_collect_fpregset (const struct sparc_fpregset *fpregset,
+sparc64nbsd_collect_fpregset (const struct sparc_fpregmap *fpregmap,
const struct regcache *regcache,
int regnum, void *fpregs)
{
int sparc32 = (gdbarch_ptr_bit (get_regcache_arch (regcache)) == 32);
if (sparc32)
- sparc32_collect_fpregset (&sparc32_bsd_fpregset, regcache, regnum, fpregs);
+ sparc32_collect_fpregset (&sparc32_bsd_fpregmap, regcache, regnum, fpregs);
else
- sparc64_collect_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_collect_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
/* Determine whether `gregset_t' contains register REGNUM. */
#include "nbsd-tdep.h"
/* From <machine/reg.h>. */
-const struct sparc_gregset sparc64nbsd_gregset =
+const struct sparc_gregmap sparc64nbsd_gregmap =
{
0 * 8, /* "tstate" */
1 * 8, /* %pc */
struct regcache *regcache,
int regnum, const void *gregs, size_t len)
{
- sparc64_supply_gregset (&sparc64nbsd_gregset, regcache, regnum, gregs);
+ sparc64_supply_gregset (&sparc64nbsd_gregmap, regcache, regnum, gregs);
}
static void
struct regcache *regcache,
int regnum, const void *fpregs, size_t len)
{
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
\f
sparc_gregset_supplies_p = sparc64obsd_gregset_supplies_p;
sparc_fpregset_supplies_p = sparc64obsd_fpregset_supplies_p;
- sparc_gregset = &sparc64nbsd_gregset;
- sparc_fpregset = &sparc64_bsd_fpregset;
+ sparc_gregmap = &sparc64nbsd_gregmap;
+ sparc_fpregmap = &sparc64_bsd_fpregmap;
/* Add some extra features to the generic SPARC target. */
obsd_add_target (sparc_target ());
match the ptrace(2) layout. */
/* From <machine/reg.h>. */
-const struct sparc_gregset sparc64obsd_gregset =
+const struct sparc_gregmap sparc64obsd_gregmap =
{
0 * 8, /* "tstate" */
1 * 8, /* %pc */
4 /* sizeof (%y) */
};
-const struct sparc_gregset sparc64obsd_core_gregset =
+const struct sparc_gregmap sparc64obsd_core_gregmap =
{
0 * 8, /* "tstate" */
1 * 8, /* %pc */
if (len < 832)
{
- sparc64_supply_gregset (&sparc64obsd_gregset, regcache, regnum, gregs);
+ sparc64_supply_gregset (&sparc64obsd_gregmap, regcache, regnum, gregs);
return;
}
- sparc64_supply_gregset (&sparc64obsd_core_gregset, regcache, regnum, gregs);
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_supply_gregset (&sparc64obsd_core_gregmap, regcache, regnum, gregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
static void
struct regcache *regcache,
int regnum, const void *fpregs, size_t len)
{
- sparc64_supply_fpregset (&sparc64_bsd_fpregset, regcache, regnum, fpregs);
+ sparc64_supply_fpregset (&sparc64_bsd_fpregmap, regcache, regnum, fpregs);
}
\f
void
_initialize_sparcnbsd_nat (void)
{
- sparc_gregset = &sparc32nbsd_gregset;
- sparc_fpregset = &sparc32_bsd_fpregset;
+ sparc_gregmap = &sparc32nbsd_gregmap;
+ sparc_fpregmap = &sparc32_bsd_fpregmap;
/* We've got nothing to add to the generic SPARC target. */
add_target (sparc_target ());
#define X_RS2(i) ((i) & 0x1f)
#define X_I(i) (((i) >> 13) & 1)
-const struct sparc_gregset sparc32nbsd_gregset =
+const struct sparc_gregmap sparc32nbsd_gregmap =
{
0 * 4, /* %psr */
1 * 4, /* %pc */
struct regcache *regcache,
int regnum, const void *gregs, size_t len)
{
- sparc32_supply_gregset (&sparc32nbsd_gregset, regcache, regnum, gregs);
+ sparc32_supply_gregset (&sparc32nbsd_gregmap, regcache, regnum, gregs);
/* Traditional NetBSD core files don't use multiple register sets.
Instead, the general-purpose and floating-point registers are
lumped together in a single section. */
if (len >= 212)
- sparc32_supply_fpregset (&sparc32_bsd_fpregset, regcache, regnum,
+ sparc32_supply_fpregset (&sparc32_bsd_fpregmap, regcache, regnum,
(const char *) gregs + 80);
}
struct regcache *regcache,
int regnum, const void *fpregs, size_t len)
{
- sparc32_supply_fpregset (&sparc32_bsd_fpregset, regcache, regnum, fpregs);
+ sparc32_supply_fpregset (&sparc32_bsd_fpregmap, regcache, regnum, fpregs);
}
\f