* arch-utils.c (generic_register_raw_size): New function.

* gdbarch.sh (REGISTER_RAW_SIZE): Use generic_register_raw_size as
the static default.
* gdbarch.c: Regenerate.
* arch-utils.h (generic_register_raw_size): Declare.

* config/mips/tm-mips.h (REGISTER_RAW_SIZE): Delete macro.
* mips-tdep.c (mips_register_raw_size): Make function static.
(mips_gdbarch_init): Initialize register_raw_size.
This commit is contained in:
Andrew Cagney
2001-12-10 04:58:31 +00:00
parent 4611fbebb1
commit 46cd78fb46
7 changed files with 37 additions and 13 deletions

View File

@ -410,8 +410,9 @@ mips_print_extra_frame_info (struct frame_info *fi)
paddr_d (fi->extra_info->proc_desc->pdr.frameoffset));
}
/* Convert between RAW and VIRTUAL registers. The RAW register size
defines the remote-gdb packet. */
/* Number of bytes of storage in the actual machine representation for
register N. NOTE: This indirectly defines the register size
transfered by the GDB protocol. */
static int mips64_transfers_32bit_regs_p = 0;
@ -429,6 +430,9 @@ mips_register_raw_size (int reg_nr)
return MIPS_REGSIZE;
}
/* Convert between RAW and VIRTUAL registers. The RAW register size
defines the remote-gdb packet. */
int
mips_register_convertible (int reg_nr)
{
@ -4075,12 +4079,13 @@ mips_gdbarch_init (struct gdbarch_info info,
gdbarch = gdbarch_alloc (&info, tdep);
tdep->elf_flags = elf_flags;
/* Initially set everything according to the ABI. */
/* Initially set everything according to the default ABI/ISA. */
set_gdbarch_short_bit (gdbarch, 16);
set_gdbarch_int_bit (gdbarch, 32);
set_gdbarch_float_bit (gdbarch, 32);
set_gdbarch_double_bit (gdbarch, 64);
set_gdbarch_long_double_bit (gdbarch, 64);
set_gdbarch_register_raw_size (gdbarch, mips_register_raw_size);
tdep->mips_abi = mips_abi;
switch (mips_abi)