aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2003-05-17 06:00:01 +0000
committerAndrew Cagney <cagney@redhat.com>2003-05-17 06:00:01 +0000
commitb8b527c5a96aec839f5c8122ffd08556f7fe0d9f (patch)
tree5c4c0628de2a1390d27d731c1c66c04f0d809b59
parent9bcf4de0ded2d7a6eeddd3523756ea2bee8b8fb4 (diff)
downloadgdb-b8b527c5a96aec839f5c8122ffd08556f7fe0d9f.zip
gdb-b8b527c5a96aec839f5c8122ffd08556f7fe0d9f.tar.gz
gdb-b8b527c5a96aec839f5c8122ffd08556f7fe0d9f.tar.bz2
2003-05-16 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTES): Rename REGISTER_BYTES. * gdbarch.h, gdbarch.c: Re-generate. * arm-linux-tdep.c (arm_linux_extract_return_value): Delete reference. * TODO (REGISTER_BYTES): Delete reference. * alpha-tdep.c (alpha_gdbarch_init): Update. * xstormy16-tdep.c (xstormy16_gdbarch_init): Update. * x86-64-tdep.c (x86_64_init_abi): Update. * vax-tdep.c (vax_gdbarch_init): Update. * v850-tdep.c (v850_gdbarch_init): Update. * sparc-tdep.c (sparc_gdbarch_init): Update. * sh-tdep.c (sh_gdbarch_init): Update. * s390-tdep.c (s390_gdbarch_init): Update. * rs6000-tdep.c (rs6000_gdbarch_init): Update. * ns32k-tdep.c (ns32k_gdbarch_init_32082): Update. (ns32k_gdbarch_init_32382): Update. * mn10300-tdep.c (mn10300_gdbarch_init): Update. * mcore-tdep.c (mcore_gdbarch_init): Update. * m68k-tdep.c (m68k_gdbarch_init): Update. * m68hc11-tdep.c (m68hc11_gdbarch_init): Update. * ia64-tdep.c (ia64_gdbarch_init): Update. * i386-tdep.c (i386_gdbarch_init): Update. * i386-linux-tdep.c (i386_linux_init_abi): Update. * hppa-tdep.c (hppa_gdbarch_init): Update. * h8300-tdep.c (h8300_gdbarch_init): Update. * frv-tdep.c (frv_gdbarch_init): Update. * cris-tdep.c (cris_gdbarch_init): Update. * avr-tdep.c (avr_gdbarch_init): Update. * arm-tdep.c (arm_gdbarch_init): Update. * sparc-tdep.c (sparc_pop_frame): Update. * rs6000-tdep.c (rs6000_pop_frame): Update. * remote.c (init_remote_state): Update. (remote_prepare_to_store): Update. * remote-vx.c (vx_prepare_to_store): Update. * remote-sds.c (sds_fetch_registers): Update. (sds_prepare_to_store): Update. * remote-array.c: Update. * regcache.c (init_legacy_regcache_descr): Update. (init_regcache_descr): Update. * mips-tdep.c (mips_eabi_extract_return_value): Update. (mips_o64_extract_return_value): Update. * irix5-nat.c (fetch_core_registers): Update. * irix4-nat.c (fetch_core_registers): Update. * i386-tdep.h: Update. * hppa-tdep.c (pa_do_registers_info): Update. (pa_do_strcat_registers_info): Update. * cris-tdep.c (cris_register_bytes_ok): Update. * config/nm-gnu.h (CHILD_PREPARE_TO_STORE): Update. * config/sparc/tm-sparc.h (DEPRECATED_REGISTER_BYTES): Update. * config/sparc/nm-sun4sol2.h (CHILD_PREPARE_TO_STORE): Update. * config/sparc/nm-sun4os4.h (CHILD_PREPARE_TO_STORE): Update. * config/sparc/nm-nbsd.h (CHILD_PREPARE_TO_STORE): Update. * config/sparc/tm-sp64.h (DEPRECATED_REGISTER_BYTES): Update. * config/s390/tm-s390.h (DEPRECATED_REGISTER_BYTES): Update. * config/pa/tm-hppa64.h (DEPRECATED_REGISTER_BYTES): Update. * config/mips/tm-mips.h (DEPRECATED_REGISTER_BYTES): Update. * config/mips/tm-irix6.h (DEPRECATED_REGISTER_BYTES): Update. * config/mips/tm-irix5.h (DEPRECATED_REGISTER_BYTES): Update. * config/m68k/tm-sun3.h (DEPRECATED_REGISTER_BYTES): Update. (REGISTER_BYTES_OK): Update. * config/m68k/nm-sun3.h (CHILD_PREPARE_TO_STORE): Update. * config/ia64/tm-ia64.h (DEPRECATED_REGISTER_BYTES): Update. Index: doc/ChangeLog 2003-05-16 Andrew Cagney <cagney@redhat.com> * gdbint.texinfo (Target Architecture Definition): Replace REGISTER_BYTES with DEPRECATED_REGISTER_BYTES. Fix typo, DEPRECATED_REGISTER_SIZE instead of REGISTER_BYTE. Index: mi/ChangeLog 2003-05-16 Andrew Cagney <cagney@redhat.com> * mi-main.c (mi_setup_architecture_data):
-rw-r--r--gdb/ChangeLog64
-rw-r--r--gdb/TODO4
-rw-r--r--gdb/alpha-tdep.c2
-rw-r--r--gdb/arm-linux-tdep.c2
-rw-r--r--gdb/arm-tdep.c8
-rw-r--r--gdb/avr-tdep.c2
-rw-r--r--gdb/config/ia64/tm-ia64.h2
-rw-r--r--gdb/config/m68k/nm-sun3.h2
-rw-r--r--gdb/config/m68k/tm-sun3.h4
-rw-r--r--gdb/config/mips/tm-irix5.h4
-rw-r--r--gdb/config/mips/tm-irix6.h4
-rw-r--r--gdb/config/mips/tm-mips.h2
-rw-r--r--gdb/config/nm-gnu.h2
-rw-r--r--gdb/config/pa/tm-hppa64.h6
-rw-r--r--gdb/config/s390/tm-s390.h4
-rw-r--r--gdb/config/sparc/nm-nbsd.h2
-rw-r--r--gdb/config/sparc/nm-sun4os4.h2
-rw-r--r--gdb/config/sparc/nm-sun4sol2.h2
-rw-r--r--gdb/config/sparc/tm-sp64.h4
-rw-r--r--gdb/config/sparc/tm-sparc.h2
-rw-r--r--gdb/cris-tdep.c4
-rw-r--r--gdb/doc/ChangeLog6
-rw-r--r--gdb/doc/gdbint.texinfo17
-rw-r--r--gdb/frv-tdep.c2
-rw-r--r--gdb/gdbarch.c30
-rw-r--r--gdb/gdbarch.h12
-rwxr-xr-xgdb/gdbarch.sh2
-rw-r--r--gdb/h8300-tdep.c2
-rw-r--r--gdb/hppa-tdep.c6
-rw-r--r--gdb/i386-linux-tdep.c2
-rw-r--r--gdb/i386-tdep.c2
-rw-r--r--gdb/i386-tdep.h2
-rw-r--r--gdb/ia64-tdep.c2
-rw-r--r--gdb/irix4-nat.c2
-rw-r--r--gdb/irix5-nat.c2
-rw-r--r--gdb/m68hc11-tdep.c2
-rw-r--r--gdb/m68k-tdep.c2
-rw-r--r--gdb/mcore-tdep.c2
-rw-r--r--gdb/mi/ChangeLog4
-rw-r--r--gdb/mi/mi-main.c6
-rw-r--r--gdb/mips-tdep.c4
-rw-r--r--gdb/mn10300-tdep.c2
-rw-r--r--gdb/ns32k-tdep.c4
-rw-r--r--gdb/regcache.c15
-rw-r--r--gdb/remote-array.c11
-rw-r--r--gdb/remote-sds.c6
-rw-r--r--gdb/remote-vx.c2
-rw-r--r--gdb/remote.c4
-rw-r--r--gdb/rs6000-tdep.c4
-rw-r--r--gdb/s390-tdep.c4
-rw-r--r--gdb/sh-tdep.c8
-rw-r--r--gdb/sparc-tdep.c12
-rw-r--r--gdb/v850-tdep.c2
-rw-r--r--gdb/vax-tdep.c2
-rw-r--r--gdb/x86-64-tdep.c2
-rw-r--r--gdb/xstormy16-tdep.c2
56 files changed, 196 insertions, 121 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 4f80600..4058661 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,67 @@
+2003-05-16 Andrew Cagney <cagney@redhat.com>
+
+ * gdbarch.sh (DEPRECATED_REGISTER_BYTES): Rename REGISTER_BYTES.
+ * gdbarch.h, gdbarch.c: Re-generate.
+ * arm-linux-tdep.c (arm_linux_extract_return_value): Delete reference.
+ * TODO (REGISTER_BYTES): Delete reference.
+ * alpha-tdep.c (alpha_gdbarch_init): Update.
+ * xstormy16-tdep.c (xstormy16_gdbarch_init): Update.
+ * x86-64-tdep.c (x86_64_init_abi): Update.
+ * vax-tdep.c (vax_gdbarch_init): Update.
+ * v850-tdep.c (v850_gdbarch_init): Update.
+ * sparc-tdep.c (sparc_gdbarch_init): Update.
+ * sh-tdep.c (sh_gdbarch_init): Update.
+ * s390-tdep.c (s390_gdbarch_init): Update.
+ * rs6000-tdep.c (rs6000_gdbarch_init): Update.
+ * ns32k-tdep.c (ns32k_gdbarch_init_32082): Update.
+ (ns32k_gdbarch_init_32382): Update.
+ * mn10300-tdep.c (mn10300_gdbarch_init): Update.
+ * mcore-tdep.c (mcore_gdbarch_init): Update.
+ * m68k-tdep.c (m68k_gdbarch_init): Update.
+ * m68hc11-tdep.c (m68hc11_gdbarch_init): Update.
+ * ia64-tdep.c (ia64_gdbarch_init): Update.
+ * i386-tdep.c (i386_gdbarch_init): Update.
+ * i386-linux-tdep.c (i386_linux_init_abi): Update.
+ * hppa-tdep.c (hppa_gdbarch_init): Update.
+ * h8300-tdep.c (h8300_gdbarch_init): Update.
+ * frv-tdep.c (frv_gdbarch_init): Update.
+ * cris-tdep.c (cris_gdbarch_init): Update.
+ * avr-tdep.c (avr_gdbarch_init): Update.
+ * arm-tdep.c (arm_gdbarch_init): Update.
+ * sparc-tdep.c (sparc_pop_frame): Update.
+ * rs6000-tdep.c (rs6000_pop_frame): Update.
+ * remote.c (init_remote_state): Update.
+ (remote_prepare_to_store): Update.
+ * remote-vx.c (vx_prepare_to_store): Update.
+ * remote-sds.c (sds_fetch_registers): Update.
+ (sds_prepare_to_store): Update.
+ * remote-array.c: Update.
+ * regcache.c (init_legacy_regcache_descr): Update.
+ (init_regcache_descr): Update.
+ * mips-tdep.c (mips_eabi_extract_return_value): Update.
+ (mips_o64_extract_return_value): Update.
+ * irix5-nat.c (fetch_core_registers): Update.
+ * irix4-nat.c (fetch_core_registers): Update.
+ * i386-tdep.h: Update.
+ * hppa-tdep.c (pa_do_registers_info): Update.
+ (pa_do_strcat_registers_info): Update.
+ * cris-tdep.c (cris_register_bytes_ok): Update.
+ * config/nm-gnu.h (CHILD_PREPARE_TO_STORE): Update.
+ * config/sparc/tm-sparc.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/sparc/nm-sun4sol2.h (CHILD_PREPARE_TO_STORE): Update.
+ * config/sparc/nm-sun4os4.h (CHILD_PREPARE_TO_STORE): Update.
+ * config/sparc/nm-nbsd.h (CHILD_PREPARE_TO_STORE): Update.
+ * config/sparc/tm-sp64.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/s390/tm-s390.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/pa/tm-hppa64.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/mips/tm-mips.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/mips/tm-irix6.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/mips/tm-irix5.h (DEPRECATED_REGISTER_BYTES): Update.
+ * config/m68k/tm-sun3.h (DEPRECATED_REGISTER_BYTES): Update.
+ (REGISTER_BYTES_OK): Update.
+ * config/m68k/nm-sun3.h (CHILD_PREPARE_TO_STORE): Update.
+ * config/ia64/tm-ia64.h (DEPRECATED_REGISTER_BYTES): Update.
+
2003-05-16 Ian Lance Taylor <ian@airs.com>
* vax-tdep.c (INVALID_FLOAT, MAXLEN, NOPCODES): Don't define.
diff --git a/gdb/TODO b/gdb/TODO
index 2a9c665..1ef9c22 100644
--- a/gdb/TODO
+++ b/gdb/TODO
@@ -171,10 +171,6 @@ Deprecate, if not delete, the following:
how it relates to rawreg and the
regnum is clear.
- REGISTER_BYTES
- The size of the cache can be computed
- on the fly.
-
--
Obsolete the targets:
diff --git a/gdb/alpha-tdep.c b/gdb/alpha-tdep.c
index a9377bc..ad7ca74 100644
--- a/gdb/alpha-tdep.c
+++ b/gdb/alpha-tdep.c
@@ -1812,7 +1812,7 @@ alpha_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, alpha_register_name);
set_gdbarch_deprecated_register_size (gdbarch, ALPHA_REGISTER_SIZE);
- set_gdbarch_register_bytes (gdbarch, ALPHA_REGISTER_BYTES);
+ set_gdbarch_deprecated_register_bytes (gdbarch, ALPHA_REGISTER_BYTES);
set_gdbarch_register_byte (gdbarch, alpha_register_byte);
set_gdbarch_register_raw_size (gdbarch, alpha_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, ALPHA_MAX_REGISTER_RAW_SIZE);
diff --git a/gdb/arm-linux-tdep.c b/gdb/arm-linux-tdep.c
index 9debbeb..a2ea493 100644
--- a/gdb/arm-linux-tdep.c
+++ b/gdb/arm-linux-tdep.c
@@ -73,7 +73,7 @@ LONGEST arm_linux_call_dummy_words[] =
hidden behind the regcache abstraction. */
static void
arm_linux_extract_return_value (struct type *type,
- char regbuf[REGISTER_BYTES],
+ char regbuf[],
char *valbuf)
{
/* ScottB: This needs to be looked at to handle the different
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index 55441e8..c0e2408 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -2976,10 +2976,10 @@ arm_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_sp_regnum (gdbarch, ARM_SP_REGNUM);
set_gdbarch_pc_regnum (gdbarch, ARM_PC_REGNUM);
set_gdbarch_register_byte (gdbarch, arm_register_byte);
- set_gdbarch_register_bytes (gdbarch,
- (NUM_GREGS * INT_REGISTER_RAW_SIZE
- + NUM_FREGS * FP_REGISTER_RAW_SIZE
- + NUM_SREGS * STATUS_REGISTER_SIZE));
+ set_gdbarch_deprecated_register_bytes (gdbarch,
+ (NUM_GREGS * INT_REGISTER_RAW_SIZE
+ + NUM_FREGS * FP_REGISTER_RAW_SIZE
+ + NUM_SREGS * STATUS_REGISTER_SIZE));
set_gdbarch_num_regs (gdbarch, NUM_GREGS + NUM_FREGS + NUM_SREGS);
set_gdbarch_register_raw_size (gdbarch, arm_register_raw_size);
set_gdbarch_register_virtual_size (gdbarch, arm_register_virtual_size);
diff --git a/gdb/avr-tdep.c b/gdb/avr-tdep.c
index 59e2c58..4ade2ab 100644
--- a/gdb/avr-tdep.c
+++ b/gdb/avr-tdep.c
@@ -1171,7 +1171,7 @@ avr_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, avr_register_name);
set_gdbarch_deprecated_register_size (gdbarch, 1);
- set_gdbarch_register_bytes (gdbarch, AVR_NUM_REG_BYTES);
+ set_gdbarch_deprecated_register_bytes (gdbarch, AVR_NUM_REG_BYTES);
set_gdbarch_register_byte (gdbarch, avr_register_byte);
set_gdbarch_register_raw_size (gdbarch, avr_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
diff --git a/gdb/config/ia64/tm-ia64.h b/gdb/config/ia64/tm-ia64.h
index feeef09..2445395 100644
--- a/gdb/config/ia64/tm-ia64.h
+++ b/gdb/config/ia64/tm-ia64.h
@@ -50,7 +50,7 @@
need 8 bytes for each register, plus an additional 8 bytes for each
of the 128 floating point registers. */
-#define REGISTER_BYTES (NUM_REGS*8+128*8)
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS*8+128*8)
/* Index within `registers' of the first byte of the space for
register N. */
diff --git a/gdb/config/m68k/nm-sun3.h b/gdb/config/m68k/nm-sun3.h
index b2fecb2..3c5d47e 100644
--- a/gdb/config/m68k/nm-sun3.h
+++ b/gdb/config/m68k/nm-sun3.h
@@ -31,4 +31,4 @@
/* We have to grab the regs since we store all regs at once. */
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
diff --git a/gdb/config/m68k/tm-sun3.h b/gdb/config/m68k/tm-sun3.h
index aafba6a..6e978cf 100644
--- a/gdb/config/m68k/tm-sun3.h
+++ b/gdb/config/m68k/tm-sun3.h
@@ -28,12 +28,12 @@
<machine/reg.h>. */
/* a&d, pc,sr, fp, fpstat, fpflags */
-#define REGISTER_BYTES (16*4 + 8 + 8*12 + 3*4 + 4)
+#define DEPRECATED_REGISTER_BYTES (16*4 + 8 + 8*12 + 3*4 + 4)
#define NUM_REGS 31
#define REGISTER_BYTES_OK(b) \
- ((b) == REGISTER_BYTES \
+ ((b) == DEPRECATED_REGISTER_BYTES \
|| (b) == REGISTER_BYTES_FP \
|| (b) == REGISTER_BYTES_NOFP)
diff --git a/gdb/config/mips/tm-irix5.h b/gdb/config/mips/tm-irix5.h
index 2a1af87..d3dfdc4 100644
--- a/gdb/config/mips/tm-irix5.h
+++ b/gdb/config/mips/tm-irix5.h
@@ -30,8 +30,8 @@
* Irix 6 (n32 ABI) has 32-bit GP regs and 64-bit FP regs
*/
-#undef REGISTER_BYTES
-#define REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
+#undef DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
#undef REGISTER_BYTE
#define REGISTER_BYTE(N) \
diff --git a/gdb/config/mips/tm-irix6.h b/gdb/config/mips/tm-irix6.h
index 59d3c58..812aed5 100644
--- a/gdb/config/mips/tm-irix6.h
+++ b/gdb/config/mips/tm-irix6.h
@@ -62,8 +62,8 @@
#define FCRIR_REGNUM 70 /* FP implementation/revision */
-#undef REGISTER_BYTES
-#define REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
+#undef DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (MIPS_NUMREGS * 8 + (NUM_REGS - MIPS_NUMREGS) * MIPS_REGSIZE)
#undef REGISTER_BYTE
#define REGISTER_BYTE(N) \
diff --git a/gdb/config/mips/tm-mips.h b/gdb/config/mips/tm-mips.h
index f9aebbe..540db16 100644
--- a/gdb/config/mips/tm-mips.h
+++ b/gdb/config/mips/tm-mips.h
@@ -106,7 +106,7 @@ extern int mips_step_skips_delay (CORE_ADDR);
/* Total amount of space needed to store our copies of the machine's
register state, the array `registers'. */
-#define REGISTER_BYTES (NUM_REGS*MIPS_REGSIZE)
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS*MIPS_REGSIZE)
/* Index within `registers' of the first byte of the space for
register N. */
diff --git a/gdb/config/nm-gnu.h b/gdb/config/nm-gnu.h
index 1dedb57..73a4180 100644
--- a/gdb/config/nm-gnu.h
+++ b/gdb/config/nm-gnu.h
@@ -30,7 +30,7 @@
extern char *gnu_target_pid_to_str (int pid);
/* Before storing, we need to read all the registers. */
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
/* Don't do wait_for_inferior on attach. */
#define ATTACH_NO_WAIT
diff --git a/gdb/config/pa/tm-hppa64.h b/gdb/config/pa/tm-hppa64.h
index 0d92311..6d39ed0 100644
--- a/gdb/config/pa/tm-hppa64.h
+++ b/gdb/config/pa/tm-hppa64.h
@@ -152,7 +152,7 @@ extern int hppa_register_raw_size (int reg_nr);
/* Total amount of space needed to store our copies of the machine's
register state, the array `registers'. */
#if !GDB_MULTI_ARCH
-#define REGISTER_BYTES (NUM_REGS * 4)
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS * 4)
#endif
#if !GDB_MULTI_ARCH
@@ -377,8 +377,8 @@ extern CORE_ADDR hppa_target_read_fp (void);
/* Total amount of space needed to store our copies of the machine's
register state, the array `registers'. */
-#undef REGISTER_BYTES
-#define REGISTER_BYTES (NUM_REGS * 8)
+#undef DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (NUM_REGS * 8)
/* Index within `registers' of the first byte of the space for
register N. */
diff --git a/gdb/config/s390/tm-s390.h b/gdb/config/s390/tm-s390.h
index 37bf770..c8a6e8d 100644
--- a/gdb/config/s390/tm-s390.h
+++ b/gdb/config/s390/tm-s390.h
@@ -95,7 +95,7 @@ int s390x_register_raw_size (int reg_nr);
#define REGISTER_RAW_SIZE(reg_nr) s390x_register_raw_size(reg_nr)
#define GDB_TARGET_IS_ESAME (1)
#define DEPRECATED_REGISTER_SIZE (8)
-#define REGISTER_BYTES S390X_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES S390X_REGISTER_BYTES
#else /* CONFIG_ARCH_S390X */
@@ -103,7 +103,7 @@ int s390_register_raw_size (int reg_nr);
#define REGISTER_RAW_SIZE(reg_nr) s390_register_raw_size(reg_nr)
#define GDB_TARGET_IS_ESAME (0)
#define DEPRECATED_REGISTER_SIZE (4)
-#define REGISTER_BYTES S390_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES S390_REGISTER_BYTES
#endif /* CONFIG_ARCH_S390X */
diff --git a/gdb/config/sparc/nm-nbsd.h b/gdb/config/sparc/nm-nbsd.h
index 41341c6..7ffd72e 100644
--- a/gdb/config/sparc/nm-nbsd.h
+++ b/gdb/config/sparc/nm-nbsd.h
@@ -30,6 +30,6 @@
/* Before storing, we need to read all the registers. */
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
#endif /* NM_NBSD_H */
diff --git a/gdb/config/sparc/nm-sun4os4.h b/gdb/config/sparc/nm-sun4os4.h
index cee2a3d..e77330c 100644
--- a/gdb/config/sparc/nm-sun4os4.h
+++ b/gdb/config/sparc/nm-sun4os4.h
@@ -30,7 +30,7 @@
/* Before storing, we need to read all the registers. */
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
/* Return sizeof user struct to callers in less machine dependent routines */
diff --git a/gdb/config/sparc/nm-sun4sol2.h b/gdb/config/sparc/nm-sun4sol2.h
index 8ad58a1..6f37162 100644
--- a/gdb/config/sparc/nm-sun4sol2.h
+++ b/gdb/config/sparc/nm-sun4sol2.h
@@ -26,7 +26,7 @@
/* Before storing, we need to read all the registers. */
-#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, REGISTER_BYTES)
+#define CHILD_PREPARE_TO_STORE() deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES)
/* Solaris PSRVADDR support does not seem to include a place for nPC. */
diff --git a/gdb/config/sparc/tm-sp64.h b/gdb/config/sparc/tm-sp64.h
index b371d12..8baa66a 100644
--- a/gdb/config/sparc/tm-sp64.h
+++ b/gdb/config/sparc/tm-sp64.h
@@ -360,8 +360,8 @@ extern void sp64_extract_return_value (struct type *, char[], char *, int);
register state, the array `registers'.
Some of the registers aren't 64 bits, but it's a lot simpler just to assume
they all are (since most of them are). */
-#undef REGISTER_BYTES
-#define REGISTER_BYTES (32*8+32*8+45*8)
+#undef DEPRECATED_REGISTER_BYTES
+#define DEPRECATED_REGISTER_BYTES (32*8+32*8+45*8)
/* Index within `registers' of the first byte of the space for
register N. */
diff --git a/gdb/config/sparc/tm-sparc.h b/gdb/config/sparc/tm-sparc.h
index 95960b2..ab18477 100644
--- a/gdb/config/sparc/tm-sparc.h
+++ b/gdb/config/sparc/tm-sparc.h
@@ -204,7 +204,7 @@ extern int sparc_intreg_size (void);
other hand, that is likely to be confusing or worse for flat
frames. */
-#define REGISTER_BYTES (32*4+32*4+8*4)
+#define DEPRECATED_REGISTER_BYTES (32*4+32*4+8*4)
/* Index within `registers' of the first byte of the space for
register N. */
diff --git a/gdb/cris-tdep.c b/gdb/cris-tdep.c
index ff2d6d2..2fbfde5 100644
--- a/gdb/cris-tdep.c
+++ b/gdb/cris-tdep.c
@@ -1042,7 +1042,7 @@ cris_register_name (int regno)
int
cris_register_bytes_ok (long bytes)
{
- return (bytes == REGISTER_BYTES);
+ return (bytes == DEPRECATED_REGISTER_BYTES);
}
/* Extract from an array regbuf containing the raw register state a function
@@ -4235,7 +4235,7 @@ cris_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
internal_error (__FILE__, __LINE__, "cris_gdbarch_init: unknown CRIS version");
}
- set_gdbarch_register_bytes (gdbarch, register_bytes);
+ set_gdbarch_deprecated_register_bytes (gdbarch, register_bytes);
/* Returns the register offset for the first byte of register regno's space
in the saved register state. */
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog
index ba39d42..3ec3958 100644
--- a/gdb/doc/ChangeLog
+++ b/gdb/doc/ChangeLog
@@ -1,3 +1,9 @@
+2003-05-16 Andrew Cagney <cagney@redhat.com>
+
+ * gdbint.texinfo (Target Architecture Definition): Replace
+ REGISTER_BYTES with DEPRECATED_REGISTER_BYTES. Fix typo,
+ DEPRECATED_REGISTER_SIZE instead of REGISTER_BYTE.
+
2003-05-14 Theodore A. Roth <troth@openavr.org>
* gdbint.texinfo (Breakpoint Handling): Correct a double negative.
diff --git a/gdb/doc/gdbint.texinfo b/gdb/doc/gdbint.texinfo
index 12bd404..3dbb81d 100644
--- a/gdb/doc/gdbint.texinfo
+++ b/gdb/doc/gdbint.texinfo
@@ -3088,9 +3088,9 @@ reason.
@item DEPRECATED_CALL_DUMMY_WORDS
@findex DEPRECATED_CALL_DUMMY_WORDS
Pointer to an array of @code{LONGEST} words of data containing
-host-byte-ordered @code{REGISTER_BYTES} sized values that partially
-specify the sequence of instructions needed for an inferior function
-call.
+host-byte-ordered @code{DEPRECATED_REGISTER_SIZE} sized values that
+partially specify the sequence of instructions needed for an inferior
+function call.
Should be deprecated in favor of a macro that uses target-byte-ordered
data.
@@ -3746,10 +3746,13 @@ This method replaces @code{DEPRECATED_CALL_DUMMY_WORDS},
@findex DEPRECATED_PUSH_DUMMY_FRAME
Used in @samp{call_function_by_hand} to create an artificial stack frame.
-@item REGISTER_BYTES
-@findex REGISTER_BYTES
-The total amount of space needed to store @value{GDBN}'s copy of the machine's
-register state.
+@item DEPRECATED_REGISTER_BYTES
+@findex DEPRECATED_REGISTER_BYTES
+The total amount of space needed to store @value{GDBN}'s copy of the
+machine's register state.
+
+This is no longer needed. @value{GDBN} instead computes the size of the
+register buffer at run-time.
@item REGISTER_NAME(@var{i})
@findex REGISTER_NAME
diff --git a/gdb/frv-tdep.c b/gdb/frv-tdep.c
index 4d8f3fe..c26af4d 100644
--- a/gdb/frv-tdep.c
+++ b/gdb/frv-tdep.c
@@ -1058,7 +1058,7 @@ frv_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, frv_register_name);
set_gdbarch_deprecated_register_size (gdbarch, 4);
- set_gdbarch_register_bytes (gdbarch, frv_num_regs * 4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, frv_num_regs * 4);
set_gdbarch_register_byte (gdbarch, frv_register_byte);
set_gdbarch_register_raw_size (gdbarch, frv_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c
index eca8d9c..976ce59 100644
--- a/gdb/gdbarch.c
+++ b/gdb/gdbarch.c
@@ -168,7 +168,7 @@ struct gdbarch
gdbarch_dwarf2_reg_to_regnum_ftype *dwarf2_reg_to_regnum;
gdbarch_register_name_ftype *register_name;
int deprecated_register_size;
- int register_bytes;
+ int deprecated_register_bytes;
gdbarch_register_byte_ftype *register_byte;
gdbarch_register_raw_size_ftype *register_raw_size;
int deprecated_max_register_raw_size;
@@ -1480,6 +1480,14 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
(long) current_gdbarch->deprecated_push_return_address
/*DEPRECATED_PUSH_RETURN_ADDRESS ()*/);
#endif
+#ifdef DEPRECATED_REGISTER_BYTES
+ fprintf_unfiltered (file,
+ "gdbarch_dump: DEPRECATED_REGISTER_BYTES # %s\n",
+ XSTRING (DEPRECATED_REGISTER_BYTES));
+ fprintf_unfiltered (file,
+ "gdbarch_dump: DEPRECATED_REGISTER_BYTES = %d\n",
+ DEPRECATED_REGISTER_BYTES);
+#endif
#ifdef DEPRECATED_REGISTER_SIZE
fprintf_unfiltered (file,
"gdbarch_dump: DEPRECATED_REGISTER_SIZE # %s\n",
@@ -2012,14 +2020,6 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
(long) current_gdbarch->register_byte
/*REGISTER_BYTE ()*/);
#endif
-#ifdef REGISTER_BYTES
- fprintf_unfiltered (file,
- "gdbarch_dump: REGISTER_BYTES # %s\n",
- XSTRING (REGISTER_BYTES));
- fprintf_unfiltered (file,
- "gdbarch_dump: REGISTER_BYTES = %d\n",
- REGISTER_BYTES);
-#endif
#ifdef REGISTER_BYTES_OK_P
fprintf_unfiltered (file,
"gdbarch_dump: %s # %s\n",
@@ -3302,19 +3302,19 @@ set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch,
}
int
-gdbarch_register_bytes (struct gdbarch *gdbarch)
+gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch)
{
gdb_assert (gdbarch != NULL);
if (gdbarch_debug >= 2)
- fprintf_unfiltered (gdb_stdlog, "gdbarch_register_bytes called\n");
- return gdbarch->register_bytes;
+ fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_register_bytes called\n");
+ return gdbarch->deprecated_register_bytes;
}
void
-set_gdbarch_register_bytes (struct gdbarch *gdbarch,
- int register_bytes)
+set_gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch,
+ int deprecated_register_bytes)
{
- gdbarch->register_bytes = register_bytes;
+ gdbarch->deprecated_register_bytes = deprecated_register_bytes;
}
int
diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h
index b76f101..e80836f 100644
--- a/gdb/gdbarch.h
+++ b/gdb/gdbarch.h
@@ -730,13 +730,13 @@ extern void set_gdbarch_deprecated_register_size (struct gdbarch *gdbarch, int d
#define DEPRECATED_REGISTER_SIZE (gdbarch_deprecated_register_size (current_gdbarch))
#endif
-extern int gdbarch_register_bytes (struct gdbarch *gdbarch);
-extern void set_gdbarch_register_bytes (struct gdbarch *gdbarch, int register_bytes);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (REGISTER_BYTES)
-#error "Non multi-arch definition of REGISTER_BYTES"
+extern int gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch);
+extern void set_gdbarch_deprecated_register_bytes (struct gdbarch *gdbarch, int deprecated_register_bytes);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_REGISTER_BYTES)
+#error "Non multi-arch definition of DEPRECATED_REGISTER_BYTES"
#endif
-#if !defined (REGISTER_BYTES)
-#define REGISTER_BYTES (gdbarch_register_bytes (current_gdbarch))
+#if !defined (DEPRECATED_REGISTER_BYTES)
+#define DEPRECATED_REGISTER_BYTES (gdbarch_deprecated_register_bytes (current_gdbarch))
#endif
/* NOTE: cagney/2002-05-02: This function with predicate has a valid
diff --git a/gdb/gdbarch.sh b/gdb/gdbarch.sh
index 5fb7085..f6106e4 100755
--- a/gdb/gdbarch.sh
+++ b/gdb/gdbarch.sh
@@ -473,7 +473,7 @@ f:2:SDB_REG_TO_REGNUM:int:sdb_reg_to_regnum:int sdb_regnr:sdb_regnr:::no_op_reg_
f:2:DWARF2_REG_TO_REGNUM:int:dwarf2_reg_to_regnum:int dwarf2_regnr:dwarf2_regnr:::no_op_reg_to_regnum::0
f:2:REGISTER_NAME:const char *:register_name:int regnr:regnr:::legacy_register_name::0
v::DEPRECATED_REGISTER_SIZE:int:deprecated_register_size
-v::REGISTER_BYTES:int:register_bytes
+v::DEPRECATED_REGISTER_BYTES:int:deprecated_register_bytes
# NOTE: cagney/2002-05-02: This function with predicate has a valid
# (callable) initial value. As a consequence, even when the predicate
# is false, the corresponding function works. This simplifies the
diff --git a/gdb/h8300-tdep.c b/gdb/h8300-tdep.c
index 3e12afd..0559805 100644
--- a/gdb/h8300-tdep.c
+++ b/gdb/h8300-tdep.c
@@ -1105,7 +1105,7 @@ h8300_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
set_gdbarch_register_name (gdbarch, h8300_register_name);
set_gdbarch_deprecated_register_size (gdbarch, BINWORD);
- set_gdbarch_register_bytes (gdbarch, E_NUM_REGS * BINWORD);
+ set_gdbarch_deprecated_register_bytes (gdbarch, E_NUM_REGS * BINWORD);
set_gdbarch_register_byte (gdbarch, h8300_register_byte);
set_gdbarch_register_raw_size (gdbarch, h8300_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, h8300h_reg_size);
diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c
index 5cedfe7..e8d62db 100644
--- a/gdb/hppa-tdep.c
+++ b/gdb/hppa-tdep.c
@@ -2537,7 +2537,7 @@ hppa_alignof (struct type *type)
void
pa_do_registers_info (int regnum, int fpregs)
{
- char raw_regs[REGISTER_BYTES];
+ char *raw_regs = alloca (DEPRECATED_REGISTER_BYTES);
int i;
/* Make a copy of gdb's save area (may cause actual
@@ -2581,7 +2581,7 @@ void
pa_do_strcat_registers_info (int regnum, int fpregs, struct ui_file *stream,
enum precision_type precision)
{
- char raw_regs[REGISTER_BYTES];
+ char *raw_regs = alloca (DEPRECATED_REGISTER_BYTES);
int i;
/* Make a copy of gdb's save area (may cause actual
@@ -5005,7 +5005,7 @@ hppa_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_pc_regnum (gdbarch, PCOQ_HEAD_REGNUM);
set_gdbarch_npc_regnum (gdbarch, PCOQ_TAIL_REGNUM);
set_gdbarch_register_raw_size (gdbarch, hppa_register_raw_size);
- set_gdbarch_register_bytes (gdbarch, hppa_num_regs * 4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, hppa_num_regs * 4);
set_gdbarch_register_byte (gdbarch, hppa_register_byte);
set_gdbarch_register_virtual_size (gdbarch, hppa_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
diff --git a/gdb/i386-linux-tdep.c b/gdb/i386-linux-tdep.c
index 2fe4d04..afff548 100644
--- a/gdb/i386-linux-tdep.c
+++ b/gdb/i386-linux-tdep.c
@@ -461,7 +461,7 @@ i386_linux_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
set_gdbarch_num_regs (gdbarch, I386_SSE_NUM_REGS + 1);
set_gdbarch_register_name (gdbarch, i386_linux_register_name);
set_gdbarch_register_reggroup_p (gdbarch, i386_linux_register_reggroup_p);
- set_gdbarch_register_bytes (gdbarch, I386_SSE_SIZEOF_REGS + 4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, I386_SSE_SIZEOF_REGS + 4);
tdep->jb_pc_offset = 20; /* From <bits/setjmp.h>. */
diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c
index 66d697d..0428c13 100644
--- a/gdb/i386-tdep.c
+++ b/gdb/i386-tdep.c
@@ -1487,7 +1487,7 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, i386_register_name);
set_gdbarch_deprecated_register_size (gdbarch, 4);
- set_gdbarch_register_bytes (gdbarch, I386_SIZEOF_GREGS + I386_SIZEOF_FREGS);
+ set_gdbarch_deprecated_register_bytes (gdbarch, I386_SIZEOF_GREGS + I386_SIZEOF_FREGS);
set_gdbarch_register_type (gdbarch, i386_register_type);
set_gdbarch_print_float_info (gdbarch, i387_print_float_info);
diff --git a/gdb/i386-tdep.h b/gdb/i386-tdep.h
index 1e0b405..1b569d9 100644
--- a/gdb/i386-tdep.h
+++ b/gdb/i386-tdep.h
@@ -148,7 +148,7 @@ extern int i386_mxcsr_regnum_p (int regnum);
/* Sizes of individual register sets. These cover the entire register
file, so summing up the sizes of those portions actually present
- yields REGISTER_BYTES. */
+ yields DEPRECATED_REGISTER_BYTES. */
#define I386_SIZEOF_GREGS (I386_NUM_GREGS * 4)
#define I386_SIZEOF_FREGS (8 * 10 + 8 * 4)
#define I386_SIZEOF_XREGS (8 * 16 + 4)
diff --git a/gdb/ia64-tdep.c b/gdb/ia64-tdep.c
index 74be498..a898f52 100644
--- a/gdb/ia64-tdep.c
+++ b/gdb/ia64-tdep.c
@@ -2242,7 +2242,7 @@ ia64_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, ia64_register_name);
set_gdbarch_deprecated_register_size (gdbarch, 8);
- set_gdbarch_register_bytes (gdbarch, ia64_num_regs * 8 + 128*8);
+ set_gdbarch_deprecated_register_bytes (gdbarch, ia64_num_regs * 8 + 128*8);
set_gdbarch_register_byte (gdbarch, ia64_register_byte);
set_gdbarch_register_raw_size (gdbarch, ia64_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, 16);
diff --git a/gdb/irix4-nat.c b/gdb/irix4-nat.c
index 63ca71e..7635495 100644
--- a/gdb/irix4-nat.c
+++ b/gdb/irix4-nat.c
@@ -178,7 +178,7 @@ static void
fetch_core_registers (char *core_reg_sect, unsigned core_reg_size,
int which, CORE_ADDR reg_addr)
{
- if (core_reg_size != REGISTER_BYTES)
+ if (core_reg_size != DEPRECATED_REGISTER_BYTES)
{
warning ("wrong size gregset struct in core file");
return;
diff --git a/gdb/irix5-nat.c b/gdb/irix5-nat.c
index 9e4f210..6128a04 100644
--- a/gdb/irix5-nat.c
+++ b/gdb/irix5-nat.c
@@ -196,7 +196,7 @@ static void
fetch_core_registers (char *core_reg_sect, unsigned core_reg_size,
int which, CORE_ADDR reg_addr)
{
- if (core_reg_size == REGISTER_BYTES)
+ if (core_reg_size == DEPRECATED_REGISTER_BYTES)
{
memcpy ((char *) deprecated_registers, core_reg_sect, core_reg_size);
}
diff --git a/gdb/m68hc11-tdep.c b/gdb/m68hc11-tdep.c
index fb17420..5d6e51e 100644
--- a/gdb/m68hc11-tdep.c
+++ b/gdb/m68hc11-tdep.c
@@ -1374,7 +1374,7 @@ m68hc11_gdbarch_init (struct gdbarch_info info,
set_gdbarch_deprecated_fp_regnum (gdbarch, SOFT_FP_REGNUM);
set_gdbarch_register_name (gdbarch, m68hc11_register_name);
set_gdbarch_deprecated_register_size (gdbarch, 2);
- set_gdbarch_register_bytes (gdbarch, M68HC11_ALL_REGS * 2);
+ set_gdbarch_deprecated_register_bytes (gdbarch, M68HC11_ALL_REGS * 2);
set_gdbarch_register_virtual_type (gdbarch, m68hc11_register_virtual_type);
set_gdbarch_pseudo_register_read (gdbarch, m68hc11_pseudo_register_read);
set_gdbarch_pseudo_register_write (gdbarch, m68hc11_pseudo_register_write);
diff --git a/gdb/m68k-tdep.c b/gdb/m68k-tdep.c
index aabb13a..71b33b4 100644
--- a/gdb/m68k-tdep.c
+++ b/gdb/m68k-tdep.c
@@ -1029,7 +1029,7 @@ m68k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_byte (gdbarch, m68k_register_byte);
set_gdbarch_num_regs (gdbarch, 29);
set_gdbarch_register_bytes_ok (gdbarch, m68k_register_bytes_ok);
- set_gdbarch_register_bytes (gdbarch, (16 * 4 + 8 + 8 * 12 + 3 * 4));
+ set_gdbarch_deprecated_register_bytes (gdbarch, (16 * 4 + 8 + 8 * 12 + 3 * 4));
set_gdbarch_sp_regnum (gdbarch, M68K_SP_REGNUM);
set_gdbarch_deprecated_fp_regnum (gdbarch, M68K_FP_REGNUM);
set_gdbarch_pc_regnum (gdbarch, M68K_PC_REGNUM);
diff --git a/gdb/mcore-tdep.c b/gdb/mcore-tdep.c
index 484c1ec..ea97ec2 100644
--- a/gdb/mcore-tdep.c
+++ b/gdb/mcore-tdep.c
@@ -1110,7 +1110,7 @@ mcore_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_virtual_size (gdbarch, mcore_register_size);
set_gdbarch_register_raw_size (gdbarch, mcore_register_size);
set_gdbarch_register_byte (gdbarch, mcore_register_byte);
- set_gdbarch_register_bytes (gdbarch, MCORE_REG_SIZE * MCORE_NUM_REGS);
+ set_gdbarch_deprecated_register_bytes (gdbarch, MCORE_REG_SIZE * MCORE_NUM_REGS);
set_gdbarch_num_regs (gdbarch, MCORE_NUM_REGS);
set_gdbarch_pc_regnum (gdbarch, 64);
set_gdbarch_sp_regnum (gdbarch, 0);
diff --git a/gdb/mi/ChangeLog b/gdb/mi/ChangeLog
index 943fd78..3b0124c 100644
--- a/gdb/mi/ChangeLog
+++ b/gdb/mi/ChangeLog
@@ -1,3 +1,7 @@
+2003-05-16 Andrew Cagney <cagney@redhat.com>
+
+ * mi-main.c (mi_setup_architecture_data):
+
2003-05-12 Elena Zannoni <ezannoni@redhat.com>
* mi-mi-cmd-stack.c (list_args_or_locals): Rename VAR_NAMESPACE to
diff --git a/gdb/mi/mi-main.c b/gdb/mi/mi-main.c
index 6158c8f..0e9cb24 100644
--- a/gdb/mi/mi-main.c
+++ b/gdb/mi/mi-main.c
@@ -1472,9 +1472,9 @@ mi_load_progress (const char *section_name,
void
mi_setup_architecture_data (void)
{
- /* don't trust REGISTER_BYTES to be zero. */
- old_regs = xmalloc (REGISTER_BYTES + 1);
- memset (old_regs, 0, REGISTER_BYTES + 1);
+ /* don't trust DEPRECATED_REGISTER_BYTES to be zero. */
+ old_regs = xmalloc (DEPRECATED_REGISTER_BYTES + 1);
+ memset (old_regs, 0, DEPRECATED_REGISTER_BYTES + 1);
}
void
diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c
index 8b5861a..23a5911 100644
--- a/gdb/mips-tdep.c
+++ b/gdb/mips-tdep.c
@@ -4561,7 +4561,7 @@ return_value_location (struct type *valtype,
static void
mips_eabi_extract_return_value (struct type *valtype,
- char regbuf[REGISTER_BYTES],
+ char regbuf[],
char *valbuf)
{
struct return_value_word lo;
@@ -4580,7 +4580,7 @@ mips_eabi_extract_return_value (struct type *valtype,
static void
mips_o64_extract_return_value (struct type *valtype,
- char regbuf[REGISTER_BYTES],
+ char regbuf[],
char *valbuf)
{
struct return_value_word lo;
diff --git a/gdb/mn10300-tdep.c b/gdb/mn10300-tdep.c
index 1d58034..c7bc58c 100644
--- a/gdb/mn10300-tdep.c
+++ b/gdb/mn10300-tdep.c
@@ -1147,7 +1147,7 @@ mn10300_gdbarch_init (struct gdbarch_info info,
set_gdbarch_num_regs (gdbarch, num_regs);
set_gdbarch_register_name (gdbarch, register_name);
set_gdbarch_deprecated_register_size (gdbarch, 4);
- set_gdbarch_register_bytes (gdbarch, num_regs * gdbarch_deprecated_register_size (gdbarch));
+ set_gdbarch_deprecated_register_bytes (gdbarch, num_regs * gdbarch_deprecated_register_size (gdbarch));
set_gdbarch_deprecated_max_register_raw_size (gdbarch, 4);
set_gdbarch_register_raw_size (gdbarch, mn10300_register_raw_size);
set_gdbarch_register_byte (gdbarch, mn10300_register_byte);
diff --git a/gdb/ns32k-tdep.c b/gdb/ns32k-tdep.c
index ef2752d..46c175c 100644
--- a/gdb/ns32k-tdep.c
+++ b/gdb/ns32k-tdep.c
@@ -512,7 +512,7 @@ ns32k_gdbarch_init_32082 (struct gdbarch *gdbarch)
set_gdbarch_num_regs (gdbarch, NS32K_NUM_REGS_32082);
set_gdbarch_register_name (gdbarch, ns32k_register_name_32082);
- set_gdbarch_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32082);
+ set_gdbarch_deprecated_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32082);
set_gdbarch_register_byte (gdbarch, ns32k_register_byte_32082);
}
@@ -522,7 +522,7 @@ ns32k_gdbarch_init_32382 (struct gdbarch *gdbarch)
set_gdbarch_num_regs (gdbarch, NS32K_NUM_REGS_32382);
set_gdbarch_register_name (gdbarch, ns32k_register_name_32382);
- set_gdbarch_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32382);
+ set_gdbarch_deprecated_register_bytes (gdbarch, NS32K_REGISTER_BYTES_32382);
set_gdbarch_register_byte (gdbarch, ns32k_register_byte_32382);
}
diff --git a/gdb/regcache.c b/gdb/regcache.c
index 4354845..09b48f0 100644
--- a/gdb/regcache.c
+++ b/gdb/regcache.c
@@ -120,12 +120,13 @@ init_legacy_regcache_descr (struct gdbarch *gdbarch,
}
/* Compute the real size of the register buffer. Start out by
- trusting REGISTER_BYTES, but then adjust it upwards should that
- be found to not be sufficient. */
- /* FIXME: cagney/2002-11-05: Instead of using REGISTER_BYTES, this
- code should, as is done in init_regcache_descr(), compute the
- total number of register bytes using the accumulated offsets. */
- descr->sizeof_cooked_registers = REGISTER_BYTES; /* OK use. */
+ trusting DEPRECATED_REGISTER_BYTES, but then adjust it upwards
+ should that be found to not be sufficient. */
+ /* FIXME: cagney/2002-11-05: Instead of using the macro
+ DEPRECATED_REGISTER_BYTES, this code should, as is done in
+ init_regcache_descr(), compute the total number of register bytes
+ using the accumulated offsets. */
+ descr->sizeof_cooked_registers = DEPRECATED_REGISTER_BYTES; /* OK */
for (i = 0; i < descr->nr_cooked_registers; i++)
{
long regend;
@@ -243,7 +244,7 @@ init_regcache_descr (struct gdbarch *gdbarch)
gdb_assert (descr->sizeof_register[i] == REGISTER_VIRTUAL_SIZE (i));
#endif
}
- /* gdb_assert (descr->sizeof_raw_registers == REGISTER_BYTES (i)); */
+ /* gdb_assert (descr->sizeof_raw_registers == DEPRECATED_REGISTER_BYTES (i)); */
return descr;
}
diff --git a/gdb/remote-array.c b/gdb/remote-array.c
index 8df9647..ff56881 100644
--- a/gdb/remote-array.c
+++ b/gdb/remote-array.c
@@ -80,11 +80,12 @@ FILE *log_file;
#endif
static int timeout = 30;
-/* Having this larger than 400 causes us to be incompatible with m68k-stub.c
- and i386-stub.c. Normally, no one would notice because it only matters
- for writing large chunks of memory (e.g. in downloads). Also, this needs
- to be more than 400 if required to hold the registers (see below, where
- we round it up based on REGISTER_BYTES). */
+/* Having this larger than 400 causes us to be incompatible with
+ m68k-stub.c and i386-stub.c. Normally, no one would notice because
+ it only matters for writing large chunks of memory (e.g. in
+ downloads). Also, this needs to be more than 400 if required to
+ hold the registers (see below, where we round it up based on
+ DEPRECATED_REGISTER_BYTES). */
#define PBUFSIZ 400
/*
diff --git a/gdb/remote-sds.c b/gdb/remote-sds.c
index ac97cde..ae397e6 100644
--- a/gdb/remote-sds.c
+++ b/gdb/remote-sds.c
@@ -473,10 +473,10 @@ sds_fetch_registers (int regno)
{
unsigned char buf[PBUFSIZ];
int i, retlen;
- char regs[REGISTER_BYTES];
+ char *regs = alloca (DEPRECATED_REGISTER_BYTES);
/* Unimplemented registers read as all bits zero. */
- memset (regs, 0, REGISTER_BYTES);
+ memset (regs, 0, DEPRECATED_REGISTER_BYTES);
buf[0] = 18;
buf[1] = 1;
@@ -509,7 +509,7 @@ static void
sds_prepare_to_store (void)
{
/* Make sure the entire registers array is valid. */
- deprecated_read_register_bytes (0, (char *) NULL, REGISTER_BYTES);
+ deprecated_read_register_bytes (0, (char *) NULL, DEPRECATED_REGISTER_BYTES);
}
/* Store register REGNO, or all registers if REGNO == -1, from the contents
diff --git a/gdb/remote-vx.c b/gdb/remote-vx.c
index d9650e3..b3fb7f2 100644
--- a/gdb/remote-vx.c
+++ b/gdb/remote-vx.c
@@ -466,7 +466,7 @@ static void
vx_prepare_to_store (void)
{
/* Fetch all registers, if any of them are not yet fetched. */
- deprecated_read_register_bytes (0, NULL, REGISTER_BYTES);
+ deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES);
}
/* Copy LEN bytes to or from remote inferior's memory starting at MEMADDR
diff --git a/gdb/remote.c b/gdb/remote.c
index b892dda..40be8e6 100644
--- a/gdb/remote.c
+++ b/gdb/remote.c
@@ -263,7 +263,7 @@ init_remote_state (struct gdbarch *gdbarch)
/* Start out by having the remote protocol mimic the existing
behavour - just copy in the description of the register cache. */
- rs->sizeof_g_packet = REGISTER_BYTES; /* OK use. */
+ rs->sizeof_g_packet = DEPRECATED_REGISTER_BYTES; /* OK */
/* Assume a 1:1 regnum<->pnum table. */
rs->regs = xcalloc (NUM_REGS + NUM_PSEUDO_REGS, sizeof (struct packet_reg));
@@ -3529,7 +3529,7 @@ remote_prepare_to_store (void)
forcing the register cache to read its and not the target
registers. */
deprecated_read_register_bytes (0, (char *) NULL,
- REGISTER_BYTES); /* OK use. */
+ DEPRECATED_REGISTER_BYTES); /* OK */
break;
case PACKET_ENABLE:
break;
diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c
index a72c9be..9776697 100644
--- a/gdb/rs6000-tdep.c
+++ b/gdb/rs6000-tdep.c
@@ -981,7 +981,7 @@ rs6000_pop_frame (void)
}
/* Make sure that all registers are valid. */
- deprecated_read_register_bytes (0, NULL, REGISTER_BYTES);
+ deprecated_read_register_bytes (0, NULL, DEPRECATED_REGISTER_BYTES);
/* Figure out previous %pc value. If the function is frameless, it is
still in the link register, otherwise walk the frames and retrieve the
@@ -2876,7 +2876,7 @@ rs6000_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_num_pseudo_regs (gdbarch, v->npregs);
set_gdbarch_register_name (gdbarch, rs6000_register_name);
set_gdbarch_deprecated_register_size (gdbarch, wordsize);
- set_gdbarch_register_bytes (gdbarch, off);
+ set_gdbarch_deprecated_register_bytes (gdbarch, off);
set_gdbarch_register_byte (gdbarch, rs6000_register_byte);
set_gdbarch_register_raw_size (gdbarch, rs6000_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, 16);
diff --git a/gdb/s390-tdep.c b/gdb/s390-tdep.c
index ded2508..c7dce06 100644
--- a/gdb/s390-tdep.c
+++ b/gdb/s390-tdep.c
@@ -1888,7 +1888,7 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_virtual_type (gdbarch, s390_register_virtual_type);
set_gdbarch_addr_bits_remove (gdbarch, s390_addr_bits_remove);
- set_gdbarch_register_bytes (gdbarch, S390_REGISTER_BYTES);
+ set_gdbarch_deprecated_register_bytes (gdbarch, S390_REGISTER_BYTES);
break;
case bfd_mach_s390_64:
set_gdbarch_deprecated_register_size (gdbarch, 8);
@@ -1900,7 +1900,7 @@ s390_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_long_bit (gdbarch, 64);
set_gdbarch_long_long_bit (gdbarch, 64);
set_gdbarch_ptr_bit (gdbarch, 64);
- set_gdbarch_register_bytes (gdbarch, S390X_REGISTER_BYTES);
+ set_gdbarch_deprecated_register_bytes (gdbarch, S390X_REGISTER_BYTES);
set_gdbarch_address_class_type_flags (gdbarch,
s390_address_class_type_flags);
set_gdbarch_address_class_type_flags_to_name (gdbarch,
diff --git a/gdb/sh-tdep.c b/gdb/sh-tdep.c
index 1c7a1dd..cbaaa36 100644
--- a/gdb/sh-tdep.c
+++ b/gdb/sh-tdep.c
@@ -4368,7 +4368,7 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_deprecated_fp_regnum (gdbarch, 14);
set_gdbarch_pc_regnum (gdbarch, 16);
set_gdbarch_deprecated_register_size (gdbarch, 4);
- set_gdbarch_register_bytes (gdbarch, SH_DEFAULT_NUM_REGS * 4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, SH_DEFAULT_NUM_REGS * 4);
set_gdbarch_deprecated_do_registers_info (gdbarch, sh_do_registers_info);
set_gdbarch_breakpoint_from_pc (gdbarch, sh_breakpoint_from_pc);
set_gdbarch_deprecated_frame_chain (gdbarch, sh_frame_chain);
@@ -4587,9 +4587,9 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
ISA16(compact) or ISA32(media). */
set_gdbarch_num_regs (gdbarch, SIM_SH64_NR_REGS);
set_gdbarch_deprecated_register_size (gdbarch, 8); /*????*/
- set_gdbarch_register_bytes (gdbarch,
- ((SIM_SH64_NR_FP_REGS + 1) * 4)
- + (SIM_SH64_NR_REGS - SIM_SH64_NR_FP_REGS -1) * 8);
+ set_gdbarch_deprecated_register_bytes (gdbarch,
+ ((SIM_SH64_NR_FP_REGS + 1) * 4)
+ + (SIM_SH64_NR_REGS - SIM_SH64_NR_FP_REGS -1) * 8);
sh_register_name = sh_sh64_register_name;
sh_show_regs = sh64_show_regs;
diff --git a/gdb/sparc-tdep.c b/gdb/sparc-tdep.c
index f278bd6..6735b08 100644
--- a/gdb/sparc-tdep.c
+++ b/gdb/sparc-tdep.c
@@ -1269,7 +1269,7 @@ sparc_pop_frame (void)
int regnum;
fsr = alloca (NUM_REGS * sizeof (CORE_ADDR));
- raw_buffer = alloca (REGISTER_BYTES);
+ raw_buffer = alloca (DEPRECATED_REGISTER_BYTES);
sparc_frame_find_saved_regs (frame, &fsr[0]);
if (SPARC_HAS_FPU)
{
@@ -3381,7 +3381,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
case bfd_mach_sparc:
set_gdbarch_deprecated_extract_return_value (gdbarch, sparc32_extract_return_value);
set_gdbarch_num_regs (gdbarch, 72);
- set_gdbarch_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
set_gdbarch_register_name (gdbarch, sparc32_register_name);
set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
#if 0
@@ -3417,7 +3417,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
case bfd_mach_sparc_v8plus:
set_gdbarch_deprecated_extract_return_value (gdbarch, sparc32_extract_return_value);
set_gdbarch_num_regs (gdbarch, 72);
- set_gdbarch_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
set_gdbarch_register_name (gdbarch, sparc32_register_name);
set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
tdep->print_insn_mach = bfd_mach_sparc;
@@ -3429,7 +3429,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
case bfd_mach_sparc_v8plusa:
set_gdbarch_deprecated_extract_return_value (gdbarch, sparc32_extract_return_value);
set_gdbarch_num_regs (gdbarch, 72);
- set_gdbarch_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
+ set_gdbarch_deprecated_register_bytes (gdbarch, 32*4 + 32*4 + 8*4);
set_gdbarch_register_name (gdbarch, sparc32_register_name);
set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
#if 0
@@ -3453,7 +3453,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
case bfd_mach_sparc_v9:
set_gdbarch_deprecated_extract_return_value (gdbarch, sparc64_extract_return_value);
set_gdbarch_num_regs (gdbarch, 125);
- set_gdbarch_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
+ set_gdbarch_deprecated_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
set_gdbarch_register_name (gdbarch, sparc64_register_name);
set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
#if 0
@@ -3465,7 +3465,7 @@ sparc_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
case bfd_mach_sparc_v9a:
set_gdbarch_deprecated_extract_return_value (gdbarch, sparc64_extract_return_value);
set_gdbarch_num_regs (gdbarch, 125);
- set_gdbarch_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
+ set_gdbarch_deprecated_register_bytes (gdbarch, 32*8 + 32*8 + 45*8);
set_gdbarch_register_name (gdbarch, sparc64_register_name);
set_gdbarch_deprecated_store_return_value (gdbarch, sparc_store_return_value);
#if 0
diff --git a/gdb/v850-tdep.c b/gdb/v850-tdep.c
index e6b238e..0f896a4 100644
--- a/gdb/v850-tdep.c
+++ b/gdb/v850-tdep.c
@@ -1230,7 +1230,7 @@ v850_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
set_gdbarch_register_name (gdbarch, v850_register_name);
set_gdbarch_deprecated_register_size (gdbarch, v850_reg_size);
- set_gdbarch_register_bytes (gdbarch, E_ALL_REGS_SIZE);
+ set_gdbarch_deprecated_register_bytes (gdbarch, E_ALL_REGS_SIZE);
set_gdbarch_register_byte (gdbarch, v850_register_byte);
set_gdbarch_register_raw_size (gdbarch, v850_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, v850_reg_size);
diff --git a/gdb/vax-tdep.c b/gdb/vax-tdep.c
index 2840b0c..814fedd 100644
--- a/gdb/vax-tdep.c
+++ b/gdb/vax-tdep.c
@@ -379,7 +379,7 @@ vax_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_register_name (gdbarch, vax_register_name);
set_gdbarch_deprecated_register_size (gdbarch, VAX_REGISTER_SIZE);
- set_gdbarch_register_bytes (gdbarch, VAX_REGISTER_BYTES);
+ set_gdbarch_deprecated_register_bytes (gdbarch, VAX_REGISTER_BYTES);
set_gdbarch_register_byte (gdbarch, vax_register_byte);
set_gdbarch_register_raw_size (gdbarch, vax_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, VAX_MAX_REGISTER_RAW_SIZE);
diff --git a/gdb/x86-64-tdep.c b/gdb/x86-64-tdep.c
index 7dd5f1e..737d565 100644
--- a/gdb/x86-64-tdep.c
+++ b/gdb/x86-64-tdep.c
@@ -961,7 +961,7 @@ x86_64_init_abi (struct gdbarch_info info, struct gdbarch *gdbarch)
SIZEOF_SSE_REGS) */
for (i = 0, sum = 0; i < X86_64_NUM_REGS; i++)
sum += x86_64_register_info_table[i].size;
- set_gdbarch_register_bytes (gdbarch, sum);
+ set_gdbarch_deprecated_register_bytes (gdbarch, sum);
set_gdbarch_register_raw_size (gdbarch, x86_64_register_raw_size);
set_gdbarch_register_byte (gdbarch, x86_64_register_byte);
diff --git a/gdb/xstormy16-tdep.c b/gdb/xstormy16-tdep.c
index e482119..f792423 100644
--- a/gdb/xstormy16-tdep.c
+++ b/gdb/xstormy16-tdep.c
@@ -1039,7 +1039,7 @@ xstormy16_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_pc_regnum (gdbarch, E_PC_REGNUM);
set_gdbarch_register_name (gdbarch, xstormy16_register_name);
set_gdbarch_deprecated_register_size (gdbarch, xstormy16_reg_size);
- set_gdbarch_register_bytes (gdbarch, E_ALL_REGS_SIZE);
+ set_gdbarch_deprecated_register_bytes (gdbarch, E_ALL_REGS_SIZE);
set_gdbarch_register_byte (gdbarch, xstormy16_register_byte);
set_gdbarch_register_raw_size (gdbarch, xstormy16_register_raw_size);
set_gdbarch_deprecated_max_register_raw_size (gdbarch, xstormy16_pc_size);