From: Andrew Cagney Date: Sat, 30 Oct 2004 23:08:18 +0000 (+0000) Subject: 2004-10-30 Andrew Cagney X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=607fc93c5df0e62dc803b98bee71e464557aa07a;p=binutils-gdb.git 2004-10-30 Andrew Cagney * mips-tdep.h (MIPS_FIRST_EMBED_REGNUM) (MIPS_LAST_EMBED_REGNUM): Add. * config/mips/tm-mips.h (FIRST_EMBED_REGNUM) (LAST_EMBED_REGNUM): Delete. * mipsv4-nat.c, mips-tdep.c, mips-linux-tdep.c: Update. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 07157b17ad4..2a3f8d39f43 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,11 @@ 2004-10-30 Andrew Cagney + * mips-tdep.h (MIPS_FIRST_EMBED_REGNUM) + (MIPS_LAST_EMBED_REGNUM): Add. + * config/mips/tm-mips.h (FIRST_EMBED_REGNUM) + (LAST_EMBED_REGNUM): Delete. + * mipsv4-nat.c, mips-tdep.c, mips-linux-tdep.c: Update. + * config/mips/tm-mips.h (PS_REGNUM): Delete. * mips-tdep.h (MIPS_PS_REGNUM): Add. * remote-vxmips.c, mipsv4-nat.c, mips-tdep.c: Update. diff --git a/gdb/config/mips/tm-mips.h b/gdb/config/mips/tm-mips.h index d404fd1185a..68c63481a41 100644 --- a/gdb/config/mips/tm-mips.h +++ b/gdb/config/mips/tm-mips.h @@ -44,9 +44,7 @@ extern int mips_step_skips_delay (CORE_ADDR); #define STEP_SKIPS_DELAY(pc) (mips_step_skips_delay (pc)) #define RA_REGNUM 31 /* Contains return address value */ -#define FIRST_EMBED_REGNUM 74 /* First CP0 register for embedded use */ #define PRID_REGNUM 89 /* Processor ID */ -#define LAST_EMBED_REGNUM 89 /* Last one */ /* Special symbol found in blocks associated with routines. We can hang mips_extra_func_info_t's off of this. */ diff --git a/gdb/mips-linux-tdep.c b/gdb/mips-linux-tdep.c index 60c62ca4fa9..6cb9c5e7af6 100644 --- a/gdb/mips-linux-tdep.c +++ b/gdb/mips-linux-tdep.c @@ -130,7 +130,7 @@ supply_gregset (elf_gregset_t *gregsetp) /* Fill inaccessible registers with zero. */ regcache_raw_supply (current_regcache, MIPS_UNUSED_REGNUM, zerobuf); - for (regi = FIRST_EMBED_REGNUM; regi < LAST_EMBED_REGNUM; regi++) + for (regi = MIPS_FIRST_EMBED_REGNUM; regi < MIPS_LAST_EMBED_REGNUM; regi++) regcache_raw_supply (current_regcache, regi, zerobuf); } @@ -409,7 +409,7 @@ mips64_supply_gregset (mips64_elf_gregset_t *gregsetp) /* Fill inaccessible registers with zero. */ regcache_raw_supply (current_regcache, MIPS_UNUSED_REGNUM, zerobuf); - for (regi = FIRST_EMBED_REGNUM; regi < LAST_EMBED_REGNUM; regi++) + for (regi = MIPS_FIRST_EMBED_REGNUM; regi < MIPS_LAST_EMBED_REGNUM; regi++) regcache_raw_supply (current_regcache, regi, zerobuf); } diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c index fb84d2f4b6a..5885d81890f 100644 --- a/gdb/mips-tdep.c +++ b/gdb/mips-tdep.c @@ -718,7 +718,7 @@ mips_register_type (struct gdbarch *gdbarch, int regnum) the ABI (with a few complications). */ if (regnum >= (NUM_REGS + mips_regnum (current_gdbarch)->fp_control_status) - && regnum <= NUM_REGS + LAST_EMBED_REGNUM) + && regnum <= NUM_REGS + MIPS_LAST_EMBED_REGNUM) /* The pseudo/cooked view of the embedded registers is always 32-bit. The raw view is handled below. */ return builtin_type_int32; @@ -5259,18 +5259,12 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file) fprintf_unfiltered (file, "mips_dump_tdep: ECOFF_REG_TO_REGNUM # %s\n", XSTRING (ECOFF_REG_TO_REGNUM (REGNUM))); - fprintf_unfiltered (file, - "mips_dump_tdep: FIRST_EMBED_REGNUM = %d\n", - FIRST_EMBED_REGNUM); fprintf_unfiltered (file, "mips_dump_tdep: DEPRECATED_IGNORE_HELPER_CALL # %s\n", XSTRING (DEPRECATED_IGNORE_HELPER_CALL (PC))); fprintf_unfiltered (file, "mips_dump_tdep: IN_SOLIB_CALL_TRAMPOLINE # %s\n", XSTRING (IN_SOLIB_CALL_TRAMPOLINE (PC, NAME))); - fprintf_unfiltered (file, - "mips_dump_tdep: LAST_EMBED_REGNUM = %d\n", - LAST_EMBED_REGNUM); #ifdef MACHINE_CPROC_FP_OFFSET fprintf_unfiltered (file, "mips_dump_tdep: MACHINE_CPROC_FP_OFFSET = %d\n", diff --git a/gdb/mips-tdep.h b/gdb/mips-tdep.h index 3c476ef5951..975dc2211d9 100644 --- a/gdb/mips-tdep.h +++ b/gdb/mips-tdep.h @@ -84,7 +84,9 @@ enum MIPS_EMBED_CAUSE_REGNUM = 36, MIPS_EMBED_PC_REGNUM = 37, MIPS_EMBED_FP0_REGNUM = 38, - MIPS_UNUSED_REGNUM = 73 /* Never used, FIXME */ + MIPS_UNUSED_REGNUM = 73, /* Never used, FIXME */ + MIPS_FIRST_EMBED_REGNUM = 74, /* First CP0 register for embedded use. */ + MIPS_LAST_EMBED_REGNUM = 89 /* Last one. */ }; /* Defined in mips-tdep.c and used in remote-mips.c */ diff --git a/gdb/mipsv4-nat.c b/gdb/mipsv4-nat.c index 5229fd5acf1..bd48c6ebd09 100644 --- a/gdb/mipsv4-nat.c +++ b/gdb/mipsv4-nat.c @@ -69,7 +69,7 @@ supply_gregset (gregset_t *gregsetp) zerobuf); regcache_raw_supply (current_regcache, DEPRECATED_FP_REGNUM, zerobuf); regcache_raw_supply (current_regcache, MIPS_UNUSED_REGNUM, zerobuf); - for (regi = FIRST_EMBED_REGNUM; regi <= LAST_EMBED_REGNUM; regi++) + for (regi = MIPS_FIRST_EMBED_REGNUM; regi <= MIPS_LAST_EMBED_REGNUM; regi++) regcache_raw_supply (current_regcache, regi, zerobuf); }