aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2004-08-03 03:09:33 +0000
committerAndrew Cagney <cagney@redhat.com>2004-08-03 03:09:33 +0000
commit1e2279c81a35ee95c0f256cd6d5fd922b4dc74af (patch)
treef93ab60db648d810aae72ffd7466bd5837bbf928 /gdb
parenta90c06b44df548fe45ee9acf2a777453480eb3d9 (diff)
downloadgdb-1e2279c81a35ee95c0f256cd6d5fd922b4dc74af.zip
gdb-1e2279c81a35ee95c0f256cd6d5fd922b4dc74af.tar.gz
gdb-1e2279c81a35ee95c0f256cd6d5fd922b4dc74af.tar.bz2
2004-08-02 Andrew Cagney <cagney@gnu.org>
* gdbarch.sh (deprecated_register_raw_size) (deprecated_register_virtual_size:int): Delete. * gdbarch.h, gdbarch.c: Re-generate. * cris-tdep.c (cris_register_size): Delete. (cris_gdbarch_init): Update. * alpha-tdep.c (alpha_register_raw_size) (alpha_register_virtual_size): Delete. (alpha_gdbarch_init): Update.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog11
-rw-r--r--gdb/alpha-tdep.c14
-rw-r--r--gdb/cris-tdep.c45
-rw-r--r--gdb/gdbarch.c94
-rw-r--r--gdb/gdbarch.h60
-rwxr-xr-xgdb/gdbarch.sh10
6 files changed, 11 insertions, 223 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 026dcb4..a04e8ed 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,16 @@
2004-08-02 Andrew Cagney <cagney@gnu.org>
+ * gdbarch.sh (deprecated_register_raw_size)
+ (deprecated_register_virtual_size:int): Delete.
+ * gdbarch.h, gdbarch.c: Re-generate.
+ * cris-tdep.c (cris_register_size): Delete.
+ (cris_gdbarch_init): Update.
+ * alpha-tdep.c (alpha_register_raw_size)
+ (alpha_register_virtual_size): Delete.
+ (alpha_gdbarch_init): Update.
+
+2004-08-02 Andrew Cagney <cagney@gnu.org>
+
* gdbarch.sh (deprecated_register_virtual_type)
(deprecated_save_dummy_frame_tos, deprecated_push_return_address)
(deprecated_dummy_write_sp): Delete.
diff --git a/gdb/alpha-tdep.c b/gdb/alpha-tdep.c
index 12c7a50..65fd5c1 100644
--- a/gdb/alpha-tdep.c
+++ b/gdb/alpha-tdep.c
@@ -145,18 +145,6 @@ alpha_register_byte (int regno)
return (regno * 8);
}
-static int
-alpha_register_raw_size (int regno)
-{
- return 8;
-}
-
-static int
-alpha_register_virtual_size (int regno)
-{
- return 8;
-}
-
/* The following represents exactly the conversion performed by
the LDS instruction. This applies to both single-precision
floating point and 32-bit integers. */
@@ -1531,8 +1519,6 @@ alpha_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, alpha_register_name);
set_gdbarch_deprecated_register_byte (gdbarch, alpha_register_byte);
- set_gdbarch_deprecated_register_raw_size (gdbarch, alpha_register_raw_size);
- set_gdbarch_deprecated_register_virtual_size (gdbarch, alpha_register_virtual_size);
set_gdbarch_register_type (gdbarch, alpha_register_type);
set_gdbarch_cannot_fetch_register (gdbarch, alpha_cannot_fetch_register);
diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
index be90dbf..0d11fd1 100644
--- a/gdb/cris-tdep.c
+++ b/gdb/cris-tdep.c
@@ -1096,45 +1096,6 @@ cris_spec_reg_applicable (struct cris_spec_reg spec_reg)
}
}
-/* Returns the register size in unit byte. Returns 0 for an unimplemented
- register, -1 for an invalid register. */
-
-static int
-cris_register_size (int regno)
-{
- int i;
- int spec_regno;
-
- if (regno >= 0 && regno < NUM_GENREGS)
- {
- /* General registers (R0 - R15) are 32 bits. */
- return 4;
- }
- else if (regno >= NUM_GENREGS && regno < NUM_REGS)
- {
- /* Special register (R16 - R31). cris_spec_regs is zero-based.
- Adjust regno accordingly. */
- spec_regno = regno - NUM_GENREGS;
-
- /* The entries in cris_spec_regs are stored in register number order,
- which means we can shortcut into the array when searching it. */
- for (i = spec_regno; cris_spec_regs[i].name != NULL; i++)
- {
- if (cris_spec_regs[i].number == spec_regno
- && cris_spec_reg_applicable (cris_spec_regs[i]))
- /* Go with the first applicable register. */
- return cris_spec_regs[i].reg_size;
- }
- /* Special register not applicable to this CRIS version. */
- return 0;
- }
- else
- {
- /* Invalid register. */
- return -1;
- }
-}
-
/* Nonzero if regno should not be fetched from the target. This is the case
for unimplemented (size 0) and non-existant registers. */
@@ -3854,12 +3815,6 @@ cris_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
in the saved register state. */
set_gdbarch_deprecated_register_byte (gdbarch, cris_register_offset);
- /* The length of the registers in the actual machine representation. */
- set_gdbarch_deprecated_register_raw_size (gdbarch, cris_register_size);
-
- /* The length of the registers in the program's representation. */
- set_gdbarch_deprecated_register_virtual_size (gdbarch, cris_register_size);
-
set_gdbarch_register_type (gdbarch, cris_register_type);
/* Dummy frame functions. */
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c
index 4c45380..d5f72ec 100644
--- a/gdb/gdbarch.c
+++ b/gdb/gdbarch.c
@@ -146,8 +146,6 @@ struct gdbarch
gdbarch_register_name_ftype *register_name;
gdbarch_register_type_ftype *register_type;
gdbarch_deprecated_register_byte_ftype *deprecated_register_byte;
- gdbarch_deprecated_register_raw_size_ftype *deprecated_register_raw_size;
- gdbarch_deprecated_register_virtual_size_ftype *deprecated_register_virtual_size;
gdbarch_unwind_dummy_id_ftype *unwind_dummy_id;
int deprecated_fp_regnum;
gdbarch_deprecated_target_read_fp_ftype *deprecated_target_read_fp;
@@ -286,8 +284,6 @@ struct gdbarch startup_gdbarch =
0, /* register_name */
0, /* register_type */
generic_register_byte, /* deprecated_register_byte */
- generic_register_size, /* deprecated_register_raw_size */
- generic_register_size, /* deprecated_register_virtual_size */
0, /* unwind_dummy_id */
-1, /* deprecated_fp_regnum */
0, /* deprecated_target_read_fp */
@@ -434,8 +430,6 @@ gdbarch_alloc (const struct gdbarch_info *info,
current_gdbarch->sdb_reg_to_regnum = no_op_reg_to_regnum;
current_gdbarch->dwarf2_reg_to_regnum = no_op_reg_to_regnum;
current_gdbarch->deprecated_register_byte = generic_register_byte;
- current_gdbarch->deprecated_register_raw_size = generic_register_size;
- current_gdbarch->deprecated_register_virtual_size = generic_register_size;
current_gdbarch->deprecated_fp_regnum = -1;
current_gdbarch->call_dummy_location = AT_ENTRY_POINT;
current_gdbarch->print_registers_info = default_print_registers_info;
@@ -560,8 +554,6 @@ verify_gdbarch (struct gdbarch *current_gdbarch)
/* Skip verify of dwarf2_reg_to_regnum, invalid_p == 0 */
/* Skip verify of register_type, has predicate */
/* Skip verify of deprecated_register_byte, has predicate */
- /* Skip verify of deprecated_register_raw_size, has predicate */
- /* Skip verify of deprecated_register_virtual_size, has predicate */
/* Skip verify of unwind_dummy_id, has predicate */
/* Skip verify of deprecated_fp_regnum, invalid_p == 0 */
/* Skip verify of deprecated_target_read_fp, has predicate */
@@ -1148,24 +1140,6 @@ gdbarch_dump (struct gdbarch *current_gdbarch, struct ui_file *file)
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_register_byte = <0x%lx>\n",
(long) current_gdbarch->deprecated_register_byte);
-#ifdef DEPRECATED_REGISTER_RAW_SIZE_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REGISTER_RAW_SIZE_P()",
- XSTRING (DEPRECATED_REGISTER_RAW_SIZE_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_deprecated_register_raw_size_p() = %d\n",
- gdbarch_deprecated_register_raw_size_p (current_gdbarch));
-#ifdef DEPRECATED_REGISTER_RAW_SIZE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REGISTER_RAW_SIZE(reg_nr)",
- XSTRING (DEPRECATED_REGISTER_RAW_SIZE (reg_nr)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_register_raw_size = <0x%lx>\n",
- (long) current_gdbarch->deprecated_register_raw_size);
#ifdef DEPRECATED_REGISTER_SIZE
fprintf_unfiltered (file,
"gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n",
@@ -1174,24 +1148,6 @@ gdbarch_dump (struct gdbarch *current_gdbarch, struct ui_file *file)
fprintf_unfiltered (file,
"gdbarch_dump: deprecated_register_size = %s\n",
paddr_d (current_gdbarch->deprecated_register_size));
-#ifdef DEPRECATED_REGISTER_VIRTUAL_SIZE_P
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REGISTER_VIRTUAL_SIZE_P()",
- XSTRING (DEPRECATED_REGISTER_VIRTUAL_SIZE_P ()));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: gdbarch_deprecated_register_virtual_size_p() = %d\n",
- gdbarch_deprecated_register_virtual_size_p (current_gdbarch));
-#ifdef DEPRECATED_REGISTER_VIRTUAL_SIZE
- fprintf_unfiltered (file,
- "gdbarch_dump: %s # %s\n",
- "DEPRECATED_REGISTER_VIRTUAL_SIZE(reg_nr)",
- XSTRING (DEPRECATED_REGISTER_VIRTUAL_SIZE (reg_nr)));
-#endif
- fprintf_unfiltered (file,
- "gdbarch_dump: deprecated_register_virtual_size = <0x%lx>\n",
- (long) current_gdbarch->deprecated_register_virtual_size);
#ifdef DEPRECATED_SAVED_PC_AFTER_CALL_P
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
@@ -2528,56 +2484,6 @@ set_gdbarch_deprecated_register_byte (struct gdbarch *gdbarch,
}
int
-gdbarch_deprecated_register_raw_size_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->deprecated_register_raw_size != generic_register_size;
-}
-
-int
-gdbarch_deprecated_register_raw_size (struct gdbarch *gdbarch, int reg_nr)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_register_raw_size != NULL);
- /* Do not check predicate: gdbarch->deprecated_register_raw_size != generic_register_size, allow call. */
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_raw_size called\n");
- return gdbarch->deprecated_register_raw_size (reg_nr);
-}
-
-void
-set_gdbarch_deprecated_register_raw_size (struct gdbarch *gdbarch,
- gdbarch_deprecated_register_raw_size_ftype deprecated_register_raw_size)
-{
- gdbarch->deprecated_register_raw_size = deprecated_register_raw_size;
-}
-
-int
-gdbarch_deprecated_register_virtual_size_p (struct gdbarch *gdbarch)
-{
- gdb_assert (gdbarch != NULL);
- return gdbarch->deprecated_register_virtual_size != generic_register_size;
-}
-
-int
-gdbarch_deprecated_register_virtual_size (struct gdbarch *gdbarch, int reg_nr)
-{
- gdb_assert (gdbarch != NULL);
- gdb_assert (gdbarch->deprecated_register_virtual_size != NULL);
- /* Do not check predicate: gdbarch->deprecated_register_virtual_size != generic_register_size, allow call. */
- if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_virtual_size called\n");
- return gdbarch->deprecated_register_virtual_size (reg_nr);
-}
-
-void
-set_gdbarch_deprecated_register_virtual_size (struct gdbarch *gdbarch,
- gdbarch_deprecated_register_virtual_size_ftype deprecated_register_virtual_size)
-{
- gdbarch->deprecated_register_virtual_size = deprecated_register_virtual_size;
-}
-
-int
gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h
index f381fec..f971a1d 100644
--- a/gdb/gdbarch.h
+++ b/gdb/gdbarch.h
@@ -487,66 +487,6 @@ extern void set_gdbarch_deprecated_register_byte (struct gdbarch *gdbarch, gdbar
#define DEPRECATED_REGISTER_BYTE(reg_nr) (gdbarch_deprecated_register_byte (current_gdbarch, reg_nr))
#endif
-/* If all registers have identical raw and virtual sizes and those
- sizes agree with the value computed from REGISTER_TYPE,
- DEPRECATED_REGISTER_RAW_SIZE can be deleted. See: maint print
- registers. */
-
-#if defined (DEPRECATED_REGISTER_RAW_SIZE)
-/* Legacy for systems yet to multi-arch DEPRECATED_REGISTER_RAW_SIZE */
-#if !defined (DEPRECATED_REGISTER_RAW_SIZE_P)
-#define DEPRECATED_REGISTER_RAW_SIZE_P() (1)
-#endif
-#endif
-
-extern int gdbarch_deprecated_register_raw_size_p (struct gdbarch *gdbarch);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_RAW_SIZE_P)
-#error "Non multi-arch definition of DEPRECATED_REGISTER_RAW_SIZE"
-#endif
-#if !defined (DEPRECATED_REGISTER_RAW_SIZE_P)
-#define DEPRECATED_REGISTER_RAW_SIZE_P() (gdbarch_deprecated_register_raw_size_p (current_gdbarch))
-#endif
-
-typedef int (gdbarch_deprecated_register_raw_size_ftype) (int reg_nr);
-extern int gdbarch_deprecated_register_raw_size (struct gdbarch *gdbarch, int reg_nr);
-extern void set_gdbarch_deprecated_register_raw_size (struct gdbarch *gdbarch, gdbarch_deprecated_register_raw_size_ftype *deprecated_register_raw_size);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_RAW_SIZE)
-#error "Non multi-arch definition of DEPRECATED_REGISTER_RAW_SIZE"
-#endif
-#if !defined (DEPRECATED_REGISTER_RAW_SIZE)
-#define DEPRECATED_REGISTER_RAW_SIZE(reg_nr) (gdbarch_deprecated_register_raw_size (current_gdbarch, reg_nr))
-#endif
-
-/* If all registers have identical raw and virtual sizes and those
- sizes agree with the value computed from REGISTER_TYPE,
- DEPRECATED_REGISTER_VIRTUAL_SIZE can be deleted. See: maint print
- registers. */
-
-#if defined (DEPRECATED_REGISTER_VIRTUAL_SIZE)
-/* Legacy for systems yet to multi-arch DEPRECATED_REGISTER_VIRTUAL_SIZE */
-#if !defined (DEPRECATED_REGISTER_VIRTUAL_SIZE_P)
-#define DEPRECATED_REGISTER_VIRTUAL_SIZE_P() (1)
-#endif
-#endif
-
-extern int gdbarch_deprecated_register_virtual_size_p (struct gdbarch *gdbarch);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_VIRTUAL_SIZE_P)
-#error "Non multi-arch definition of DEPRECATED_REGISTER_VIRTUAL_SIZE"
-#endif
-#if !defined (DEPRECATED_REGISTER_VIRTUAL_SIZE_P)
-#define DEPRECATED_REGISTER_VIRTUAL_SIZE_P() (gdbarch_deprecated_register_virtual_size_p (current_gdbarch))
-#endif
-
-typedef int (gdbarch_deprecated_register_virtual_size_ftype) (int reg_nr);
-extern int gdbarch_deprecated_register_virtual_size (struct gdbarch *gdbarch, int reg_nr);
-extern void set_gdbarch_deprecated_register_virtual_size (struct gdbarch *gdbarch, gdbarch_deprecated_register_virtual_size_ftype *deprecated_register_virtual_size);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_VIRTUAL_SIZE)
-#error "Non multi-arch definition of DEPRECATED_REGISTER_VIRTUAL_SIZE"
-#endif
-#if !defined (DEPRECATED_REGISTER_VIRTUAL_SIZE)
-#define DEPRECATED_REGISTER_VIRTUAL_SIZE(reg_nr) (gdbarch_deprecated_register_virtual_size (current_gdbarch, reg_nr))
-#endif
-
/* See gdbint.texinfo, and PUSH_DUMMY_CALL. */
extern int gdbarch_unwind_dummy_id_p (struct gdbarch *gdbarch);
diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh
index 2f89c8b..f615069 100755
--- a/gdb/gdbarch.sh
+++ b/gdb/gdbarch.sh
@@ -469,16 +469,6 @@ M::struct type *:register_type:int reg_nr:reg_nr
# function works. This simplifies the migration process - old code,
# calling DEPRECATED_REGISTER_BYTE, doesn't need to be modified.
F:=:int:deprecated_register_byte:int reg_nr:reg_nr::generic_register_byte:generic_register_byte
-# If all registers have identical raw and virtual sizes and those
-# sizes agree with the value computed from REGISTER_TYPE,
-# DEPRECATED_REGISTER_RAW_SIZE can be deleted. See: maint print
-# registers.
-F:=:int:deprecated_register_raw_size:int reg_nr:reg_nr::generic_register_size:generic_register_size
-# If all registers have identical raw and virtual sizes and those
-# sizes agree with the value computed from REGISTER_TYPE,
-# DEPRECATED_REGISTER_VIRTUAL_SIZE can be deleted. See: maint print
-# registers.
-F:=:int:deprecated_register_virtual_size:int reg_nr:reg_nr::generic_register_size:generic_register_size
# See gdbint.texinfo, and PUSH_DUMMY_CALL.
M::struct frame_id:unwind_dummy_id:struct frame_info *info:info