2002-10-26 Andrew Cagney <cagney@redhat.com>
authorAndrew Cagney <cagney@redhat.com>
Sat, 26 Oct 2002 17:19:28 +0000 (17:19 +0000)
committerAndrew Cagney <cagney@redhat.com>
Sat, 26 Oct 2002 17:19:28 +0000 (17:19 +0000)
* gdbint.texinfo (Target Architecture Definition): Delete
definition of DO_REGISTERS_INFO.

2002-10-26  Andrew Cagney  <cagney@redhat.com>

* gdbarch.sh (DEPRECATED_DO_REGISTERS_INFO): Rename
DO_REGISTERS_INFO.
gdbarch.h, gdbarch.c: Re-generate.
* infcmd.c (default_print_registers_info): Update reference.
* mips-tdep.c (mips_gdbarch_init): Set deprecated_do_registers_info.
(mips_dump_tdep): Do not print DO_REGISTERS_INFO.
* sh-tdep.c (sh_gdbarch_init): Ditto.
* mn10300-tdep.c (mn10300_gdbarch_init): Ditto.
* h8300-tdep.c (h8300_gdbarch_init): Ditto.

12 files changed:
gdb/ChangeLog
gdb/config/pa/tm-hppa.h
gdb/doc/ChangeLog
gdb/doc/gdbint.texinfo
gdb/gdbarch.c
gdb/gdbarch.h
gdb/gdbarch.sh
gdb/h8300-tdep.c
gdb/infcmd.c
gdb/mips-tdep.c
gdb/mn10300-tdep.c
gdb/sh-tdep.c

index 85da82fda8d9fc7d2a3f9ea90d37b380a46f4a89..220366bb42716a77d19fc410b593adf1bb0f3a76 100644 (file)
@@ -1,3 +1,15 @@
+2002-10-26  Andrew Cagney  <cagney@redhat.com>
+
+       * gdbarch.sh (DEPRECATED_DO_REGISTERS_INFO): Rename
+       DO_REGISTERS_INFO.
+       gdbarch.h, gdbarch.c: Re-generate.
+       * infcmd.c (default_print_registers_info): Update reference.
+       * mips-tdep.c (mips_gdbarch_init): Set deprecated_do_registers_info.
+       (mips_dump_tdep): Do not print DO_REGISTERS_INFO.
+       * sh-tdep.c (sh_gdbarch_init): Ditto.
+       * mn10300-tdep.c (mn10300_gdbarch_init): Ditto.
+       * h8300-tdep.c (h8300_gdbarch_init): Ditto.
+
 2002-10-26  Mark Kettenis  <kettenis@gnu.org>
 
        * x86-64-tdep.c (x86_64_init_abi): Set init_extra_frame_info to
index 6fd8c03365263f44356e627b1ded8d72a8dabd46..272078fbcb057b039bb5b752563df2ece8952954 100644 (file)
@@ -249,10 +249,10 @@ extern CORE_ADDR saved_pc_after_call (struct frame_info *);
       (buf)[sizeof(CORE_ADDR) -1] &= ~0x3; \
   } while (0)
 
-/* Define DO_REGISTERS_INFO() to do machine-specific formatting
+/* Define DEPRECATED_REGISTERS_INFO() to do machine-specific formatting
    of register dumps. */
 
-#define DO_REGISTERS_INFO(_regnum, fp) pa_do_registers_info (_regnum, fp)
+#define DEPRECATED_REGISTERS_INFO(_regnum, fp) pa_do_registers_info (_regnum, fp)
 extern void pa_do_registers_info (int, int);
 
 #if 0
index 1923c8bf8733728ed2317b23991912399193a182..7f05283d24b9fb5a7491329de3b93f3445c7c1a7 100644 (file)
@@ -1,3 +1,8 @@
+2002-10-26  Andrew Cagney  <cagney@redhat.com>
+
+       * gdbint.texinfo (Target Architecture Definition): Delete
+       definition of DO_REGISTERS_INFO.
+
 2002-10-18  Kevin Buettner  <kevinb@redhat.com>
 
        * gdbint.texinfo (Address Classes): Fix problems with insertion
index cdb06b2ff36c031a5aec0192f583cda48f91c4c0..0cdbc053376e3364979d79165a85916e7fff5a5a 100644 (file)
@@ -3218,12 +3218,6 @@ Similarly, for hardware breakpoints.
 If defined, this should evaluate to 1 if @var{addr} is in a shared
 library in which breakpoints cannot be set and so should be disabled.
 
-@item DO_REGISTERS_INFO
-@findex DO_REGISTERS_INFO
-If defined, use this to print the value of a register or all registers.
-
-This method is deprecated.
-
 @item PRINT_FLOAT_INFO()
 @findex PRINT_FLOAT_INFO
 If defined, then the @samp{info float} command will print information about
index 901c47e4f7a9aa1a160b7d411f6d412d93380ddd..b34e56506b12bb2cc2f0aab9213136e27b4c3999 100644 (file)
@@ -171,7 +171,7 @@ struct gdbarch
   gdbarch_register_virtual_size_ftype *register_virtual_size;
   int max_register_virtual_size;
   gdbarch_register_virtual_type_ftype *register_virtual_type;
-  gdbarch_do_registers_info_ftype *do_registers_info;
+  gdbarch_deprecated_do_registers_info_ftype *deprecated_do_registers_info;
   gdbarch_print_registers_info_ftype *print_registers_info;
   gdbarch_print_float_info_ftype *print_float_info;
   gdbarch_print_vector_info_ftype *print_vector_info;
@@ -664,7 +664,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
   if ((GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL)
       && (gdbarch->register_virtual_type == 0))
     fprintf_unfiltered (log, "\n\tregister_virtual_type");
-  /* Skip verify of do_registers_info, has predicate */
+  /* Skip verify of deprecated_do_registers_info, has predicate */
   /* Skip verify of print_registers_info, invalid_p == 0 */
   /* Skip verify of print_float_info, has predicate */
   /* Skip verify of print_vector_info, has predicate */
@@ -1105,6 +1105,20 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
                       "gdbarch_dump: DECR_PC_AFTER_BREAK = %ld\n",
                       (long) DECR_PC_AFTER_BREAK);
 #endif
+#ifdef DEPRECATED_DO_REGISTERS_INFO
+#if GDB_MULTI_ARCH
+  /* Macro might contain `[{}]' when not multi-arch */
+  fprintf_unfiltered (file,
+                      "gdbarch_dump: %s # %s\n",
+                      "DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs)",
+                      XSTRING (DEPRECATED_DO_REGISTERS_INFO (reg_nr, fpregs)));
+#endif
+  if (GDB_MULTI_ARCH)
+    fprintf_unfiltered (file,
+                        "gdbarch_dump: DEPRECATED_DO_REGISTERS_INFO = 0x%08lx\n",
+                        (long) current_gdbarch->deprecated_do_registers_info
+                        /*DEPRECATED_DO_REGISTERS_INFO ()*/);
+#endif
 #ifdef DEPRECATED_EXTRACT_RETURN_VALUE
 #if GDB_MULTI_ARCH
   /* Macro might contain `[{}]' when not multi-arch */
@@ -1144,20 +1158,6 @@ gdbarch_dump (struct gdbarch *gdbarch, struct ui_file *file)
                         (long) current_gdbarch->deprecated_store_return_value
                         /*DEPRECATED_STORE_RETURN_VALUE ()*/);
 #endif
-#ifdef DO_REGISTERS_INFO
-#if GDB_MULTI_ARCH
-  /* Macro might contain `[{}]' when not multi-arch */
-  fprintf_unfiltered (file,
-                      "gdbarch_dump: %s # %s\n",
-                      "DO_REGISTERS_INFO(reg_nr, fpregs)",
-                      XSTRING (DO_REGISTERS_INFO (reg_nr, fpregs)));
-#endif
-  if (GDB_MULTI_ARCH)
-    fprintf_unfiltered (file,
-                        "gdbarch_dump: DO_REGISTERS_INFO = 0x%08lx\n",
-                        (long) current_gdbarch->do_registers_info
-                        /*DO_REGISTERS_INFO ()*/);
-#endif
 #ifdef DWARF2_BUILD_FRAME_INFO
 #if GDB_MULTI_ARCH
   /* Macro might contain `[{}]' when not multi-arch */
@@ -3113,29 +3113,29 @@ set_gdbarch_register_virtual_type (struct gdbarch *gdbarch,
 }
 
 int
-gdbarch_do_registers_info_p (struct gdbarch *gdbarch)
+gdbarch_deprecated_do_registers_info_p (struct gdbarch *gdbarch)
 {
   gdb_assert (gdbarch != NULL);
-  return gdbarch->do_registers_info != 0;
+  return gdbarch->deprecated_do_registers_info != 0;
 }
 
 void
-gdbarch_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs)
+gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs)
 {
   gdb_assert (gdbarch != NULL);
-  if (gdbarch->do_registers_info == 0)
+  if (gdbarch->deprecated_do_registers_info == 0)
     internal_error (__FILE__, __LINE__,
-                    "gdbarch: gdbarch_do_registers_info invalid");
+                    "gdbarch: gdbarch_deprecated_do_registers_info invalid");
   if (gdbarch_debug >= 2)
-    fprintf_unfiltered (gdb_stdlog, "gdbarch_do_registers_info called\n");
-  gdbarch->do_registers_info (reg_nr, fpregs);
+    fprintf_unfiltered (gdb_stdlog, "gdbarch_deprecated_do_registers_info called\n");
+  gdbarch->deprecated_do_registers_info (reg_nr, fpregs);
 }
 
 void
-set_gdbarch_do_registers_info (struct gdbarch *gdbarch,
-                               gdbarch_do_registers_info_ftype do_registers_info)
+set_gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch,
+                                          gdbarch_deprecated_do_registers_info_ftype deprecated_do_registers_info)
 {
-  gdbarch->do_registers_info = do_registers_info;
+  gdbarch->deprecated_do_registers_info = deprecated_do_registers_info;
 }
 
 void
index 994ae8262a6dd14762d56cf67d9c1527f5a43ff1..524071a1d2d12affb9dde9782a21a7267bdca70b 100644 (file)
@@ -778,40 +778,40 @@ extern void set_gdbarch_register_virtual_type (struct gdbarch *gdbarch, gdbarch_
 #endif
 #endif
 
-#if defined (DO_REGISTERS_INFO)
-/* Legacy for systems yet to multi-arch DO_REGISTERS_INFO */
-#if !defined (DO_REGISTERS_INFO_P)
-#define DO_REGISTERS_INFO_P() (1)
+#if defined (DEPRECATED_DO_REGISTERS_INFO)
+/* Legacy for systems yet to multi-arch DEPRECATED_DO_REGISTERS_INFO */
+#if !defined (DEPRECATED_DO_REGISTERS_INFO_P)
+#define DEPRECATED_DO_REGISTERS_INFO_P() (1)
 #endif
 #endif
 
 /* Default predicate for non- multi-arch targets. */
-#if (!GDB_MULTI_ARCH) && !defined (DO_REGISTERS_INFO_P)
-#define DO_REGISTERS_INFO_P() (0)
+#if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_DO_REGISTERS_INFO_P)
+#define DEPRECATED_DO_REGISTERS_INFO_P() (0)
 #endif
 
-extern int gdbarch_do_registers_info_p (struct gdbarch *gdbarch);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DO_REGISTERS_INFO_P)
-#error "Non multi-arch definition of DO_REGISTERS_INFO"
+extern int gdbarch_deprecated_do_registers_info_p (struct gdbarch *gdbarch);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_DO_REGISTERS_INFO_P)
+#error "Non multi-arch definition of DEPRECATED_DO_REGISTERS_INFO"
 #endif
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DO_REGISTERS_INFO_P)
-#define DO_REGISTERS_INFO_P() (gdbarch_do_registers_info_p (current_gdbarch))
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_DO_REGISTERS_INFO_P)
+#define DEPRECATED_DO_REGISTERS_INFO_P() (gdbarch_deprecated_do_registers_info_p (current_gdbarch))
 #endif
 
 /* Default (function) for non- multi-arch platforms. */
-#if (!GDB_MULTI_ARCH) && !defined (DO_REGISTERS_INFO)
-#define DO_REGISTERS_INFO(reg_nr, fpregs) (internal_error (__FILE__, __LINE__, "DO_REGISTERS_INFO"), 0)
+#if (!GDB_MULTI_ARCH) && !defined (DEPRECATED_DO_REGISTERS_INFO)
+#define DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs) (internal_error (__FILE__, __LINE__, "DEPRECATED_DO_REGISTERS_INFO"), 0)
 #endif
 
-typedef void (gdbarch_do_registers_info_ftype) (int reg_nr, int fpregs);
-extern void gdbarch_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs);
-extern void set_gdbarch_do_registers_info (struct gdbarch *gdbarch, gdbarch_do_registers_info_ftype *do_registers_info);
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DO_REGISTERS_INFO)
-#error "Non multi-arch definition of DO_REGISTERS_INFO"
+typedef void (gdbarch_deprecated_do_registers_info_ftype) (int reg_nr, int fpregs);
+extern void gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, int reg_nr, int fpregs);
+extern void set_gdbarch_deprecated_do_registers_info (struct gdbarch *gdbarch, gdbarch_deprecated_do_registers_info_ftype *deprecated_do_registers_info);
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (DEPRECATED_DO_REGISTERS_INFO)
+#error "Non multi-arch definition of DEPRECATED_DO_REGISTERS_INFO"
 #endif
 #if GDB_MULTI_ARCH
-#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DO_REGISTERS_INFO)
-#define DO_REGISTERS_INFO(reg_nr, fpregs) (gdbarch_do_registers_info (current_gdbarch, reg_nr, fpregs))
+#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (DEPRECATED_DO_REGISTERS_INFO)
+#define DEPRECATED_DO_REGISTERS_INFO(reg_nr, fpregs) (gdbarch_deprecated_do_registers_info (current_gdbarch, reg_nr, fpregs))
 #endif
 #endif
 
index 6c9ac048bc6082d10c982875ac76adbc63e92f92..da0e76010f7f1d79daf5125e3f86d7ff900d5bfa 100755 (executable)
@@ -468,7 +468,7 @@ f:2:REGISTER_VIRTUAL_SIZE:int:register_virtual_size:int reg_nr:reg_nr::generic_r
 v:2:MAX_REGISTER_VIRTUAL_SIZE:int:max_register_virtual_size::::0:-1
 f:2:REGISTER_VIRTUAL_TYPE:struct type *:register_virtual_type:int reg_nr:reg_nr::0:0
 #
-F:2:DO_REGISTERS_INFO:void:do_registers_info:int reg_nr, int fpregs:reg_nr, fpregs
+F:2:DEPRECATED_DO_REGISTERS_INFO:void:deprecated_do_registers_info:int reg_nr, int fpregs:reg_nr, fpregs
 m:2:PRINT_REGISTERS_INFO:void:print_registers_info:struct ui_file *file, struct frame_info *frame, int regnum, int all:file, frame, regnum, all:::default_print_registers_info::0
 M:2:PRINT_FLOAT_INFO:void:print_float_info:struct ui_file *file, struct frame_info *frame, const char *args:file, frame, args
 M:2:PRINT_VECTOR_INFO:void:print_vector_info:struct ui_file *file, struct frame_info *frame, const char *args:file, frame, args
index affd8dd58ec6bb6c67d7b289307dc1cf94a45b1b..57f51fcff4377c706787845b6e84204ae7132436 100644 (file)
@@ -1085,7 +1085,7 @@ h8300_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_register_virtual_size (gdbarch, h8300_register_raw_size);
   set_gdbarch_max_register_virtual_size (gdbarch, h8300h_reg_size);
   set_gdbarch_register_virtual_type (gdbarch, h8300_register_virtual_type);
-  set_gdbarch_do_registers_info (gdbarch, h8300_do_registers_info);
+  set_gdbarch_deprecated_do_registers_info (gdbarch, h8300_do_registers_info);
   set_gdbarch_print_float_info (gdbarch, h8300_print_float_info);
 
   /*
index 5359e290e7b59b316220b79a03bba18654c76340..38cb1b69a4b1532bc703e16134b83b284cbbcebb 100644 (file)
@@ -1571,10 +1571,9 @@ default_print_registers_info (struct gdbarch *gdbarch,
   char *raw_buffer = alloca (MAX_REGISTER_RAW_SIZE);
   char *virtual_buffer = alloca (MAX_REGISTER_VIRTUAL_SIZE);
 
-  /* FIXME: cagney/2002-03-08: This should be deprecated.  */
-  if (DO_REGISTERS_INFO_P ())
+  if (DEPRECATED_DO_REGISTERS_INFO_P ())
     {
-      DO_REGISTERS_INFO (regnum, print_all);
+      DEPRECATED_DO_REGISTERS_INFO (regnum, print_all);
       return;
     }
 
index 39086066332a7b237ead1952b1384421eb92970e..75f1c84ff1437b1c223e7e2f4058bfc95c4fd630 100644 (file)
@@ -6060,7 +6060,7 @@ mips_gdbarch_init (struct gdbarch_info info,
   set_gdbarch_register_virtual_type (gdbarch, mips_register_virtual_type);
   set_gdbarch_register_virtual_size (gdbarch, generic_register_size);
 
-  set_gdbarch_do_registers_info (gdbarch, mips_do_registers_info);
+  set_gdbarch_deprecated_do_registers_info (gdbarch, mips_do_registers_info);
   set_gdbarch_pc_in_sigtramp (gdbarch, mips_pc_in_sigtramp);
 
   /* Hook in OS ABI-specific overrides, if they have been registered.  */
@@ -6193,9 +6193,6 @@ mips_dump_tdep (struct gdbarch *current_gdbarch, struct ui_file *file)
   fprintf_unfiltered (file,
                      "mips_dump_tdep: CAUSE_REGNUM = %d\n",
                      CAUSE_REGNUM);
-  fprintf_unfiltered (file,
-                     "mips_dump_tdep: DO_REGISTERS_INFO # %s\n",
-                     XSTRING (DO_REGISTERS_INFO));
   fprintf_unfiltered (file,
                      "mips_dump_tdep: DWARF_REG_TO_REGNUM # %s\n",
                      XSTRING (DWARF_REG_TO_REGNUM (REGNUM)));
index 6e7bada4cad5de073047d4d56123d4b4b89c4c1c..a5536b1e74fa53ba6bc91718fe342b65b1a4d4cc 100644 (file)
@@ -1148,7 +1148,7 @@ mn10300_gdbarch_init (struct gdbarch_info info,
   set_gdbarch_register_virtual_size (gdbarch, mn10300_register_virtual_size);
   set_gdbarch_register_virtual_type (gdbarch, mn10300_register_virtual_type);
   set_gdbarch_dwarf2_reg_to_regnum (gdbarch, mn10300_dwarf2_reg_to_regnum);
-  set_gdbarch_do_registers_info (gdbarch, mn10300_do_registers_info);
+  set_gdbarch_deprecated_do_registers_info (gdbarch, mn10300_do_registers_info);
   set_gdbarch_sp_regnum (gdbarch, 8);
   set_gdbarch_pc_regnum (gdbarch, 9);
   set_gdbarch_fp_regnum (gdbarch, 31);
index c5e5bf457d2793daac229ad252e181807adf1f0f..31db4c878065efa17a5ce070e48342b044570882 100644 (file)
@@ -4289,7 +4289,7 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_pc_regnum (gdbarch, 16);
   set_gdbarch_register_size (gdbarch, 4);
   set_gdbarch_register_bytes (gdbarch, SH_DEFAULT_NUM_REGS * 4);
-  set_gdbarch_do_registers_info (gdbarch, sh_do_registers_info);
+  set_gdbarch_deprecated_do_registers_info (gdbarch, sh_do_registers_info);
   set_gdbarch_breakpoint_from_pc (gdbarch, sh_breakpoint_from_pc);
   set_gdbarch_frame_chain (gdbarch, sh_frame_chain);
   set_gdbarch_get_saved_register (gdbarch, generic_get_saved_register);
@@ -4516,7 +4516,7 @@ sh_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
       set_gdbarch_pseudo_register_read (gdbarch, sh64_pseudo_register_read);
       set_gdbarch_pseudo_register_write (gdbarch, sh64_pseudo_register_write);
 
-      set_gdbarch_do_registers_info (gdbarch, sh64_do_registers_info);
+      set_gdbarch_deprecated_do_registers_info (gdbarch, sh64_do_registers_info);
       set_gdbarch_frame_init_saved_regs (gdbarch, sh64_nofp_frame_init_saved_regs);
       set_gdbarch_breakpoint_from_pc (gdbarch, sh_sh64_breakpoint_from_pc);
       set_gdbarch_init_extra_frame_info (gdbarch, sh64_init_extra_frame_info);