2002-08-13 Andrew Cagney <ac131313@redhat.com>
authorAndrew Cagney <cagney@redhat.com>
Wed, 14 Aug 2002 00:23:59 +0000 (00:23 +0000)
committerAndrew Cagney <cagney@redhat.com>
Wed, 14 Aug 2002 00:23:59 +0000 (00:23 +0000)
* vax-tdep.c (vax_get_saved_register): Delete function.
(vax_gdbarch_init): Update.
* ns32k-tdep.c (ns32k_get_saved_register): Delete function.
(ns32k_gdbarch_init): Update.
* alpha-tdep.c (alpha_get_saved_register): Delete function.
(alpha_gdbarch_init): Update.

gdb/ChangeLog
gdb/alpha-tdep.c
gdb/ns32k-tdep.c
gdb/vax-tdep.c

index a34f45aa5c1ecab1cf92a47ea62c318932e2273d..91afc311aa76cd7be53b54b73b5223bb7d8f280b 100644 (file)
@@ -1,3 +1,12 @@
+2002-08-13  Andrew Cagney  <ac131313@redhat.com>
+
+       * vax-tdep.c (vax_get_saved_register): Delete function.
+       (vax_gdbarch_init): Update.
+       * ns32k-tdep.c (ns32k_get_saved_register): Delete function.
+       (ns32k_gdbarch_init): Update.
+       * alpha-tdep.c (alpha_get_saved_register): Delete function.
+       (alpha_gdbarch_init): Update.
+
 2002-08-13  Andrew Cagney  <cagney@redhat.com>
 
        * regcache.c (init_regcache_descr): Overallocate the
index 564896fdc9444e0589a16a7d0860f4cabe62db6b..0f5f7d7910bd2b6e2489acbde31972cd8b4b1325 100644 (file)
@@ -65,7 +65,6 @@ static gdbarch_frame_args_address_ftype alpha_frame_args_address;
 static gdbarch_frame_locals_address_ftype alpha_frame_locals_address;
 
 static gdbarch_skip_prologue_ftype alpha_skip_prologue;
-static gdbarch_get_saved_register_ftype alpha_get_saved_register;
 static gdbarch_saved_pc_after_call_ftype alpha_saved_pc_after_call;
 static gdbarch_frame_chain_ftype alpha_frame_chain;
 static gdbarch_frame_saved_pc_ftype alpha_frame_saved_pc;
@@ -501,54 +500,6 @@ alpha_frame_saved_pc (struct frame_info *frame)
   return read_next_frame_reg (frame, pcreg);
 }
 
-static void
-alpha_get_saved_register (char *raw_buffer,
-                         int *optimized,
-                         CORE_ADDR *addrp,
-                         struct frame_info *frame,
-                         int regnum,
-                         enum lval_type *lval)
-{
-  CORE_ADDR addr;
-
-  if (!target_has_registers)
-    error ("No registers.");
-
-  /* Normal systems don't optimize out things with register numbers.  */
-  if (optimized != NULL)
-    *optimized = 0;
-  addr = find_saved_register (frame, regnum);
-  if (addr != 0)
-    {
-      if (lval != NULL)
-       *lval = lval_memory;
-      if (regnum == SP_REGNUM)
-       {
-         if (raw_buffer != NULL)
-           {
-             /* Put it back in target format.  */
-             store_address (raw_buffer, REGISTER_RAW_SIZE (regnum),
-                            (LONGEST) addr);
-           }
-         if (addrp != NULL)
-           *addrp = 0;
-         return;
-       }
-      if (raw_buffer != NULL)
-       target_read_memory (addr, raw_buffer, REGISTER_RAW_SIZE (regnum));
-    }
-  else
-    {
-      if (lval != NULL)
-       *lval = lval_register;
-      addr = REGISTER_BYTE (regnum);
-      if (raw_buffer != NULL)
-       read_register_gen (regnum, raw_buffer);
-    }
-  if (addrp != NULL)
-    *addrp = addr;
-}
-
 static CORE_ADDR
 alpha_saved_pc_after_call (struct frame_info *frame)
 {
@@ -1904,7 +1855,6 @@ alpha_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
   set_gdbarch_frame_saved_pc (gdbarch, alpha_frame_saved_pc);
 
   set_gdbarch_frame_init_saved_regs (gdbarch, alpha_frame_init_saved_regs);
-  set_gdbarch_get_saved_register (gdbarch, alpha_get_saved_register);
 
   set_gdbarch_use_struct_convention (gdbarch, alpha_use_struct_convention);
   set_gdbarch_deprecated_extract_return_value (gdbarch, alpha_extract_return_value);
index ae81ebe4eb59521dd9f72783901408d508d46476..01e89d4388d5298cfd7e8c775a95513d77771e34 100644 (file)
@@ -337,51 +337,6 @@ ns32k_frame_locals_address (struct frame_info *frame)
   return (frame->frame);
 }
 
-static void
-ns32k_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
-                          struct frame_info *frame, int regnum,
-                         enum lval_type *lval)
-{
-  CORE_ADDR addr;
-
-  if (!target_has_registers)
-    error ("No registers.");
-
-  /* Normal systems don't optimize out things with register numbers.  */
-  if (optimized != NULL)
-    *optimized = 0;
-  addr = find_saved_register (frame, regnum);
-  if (addr != 0)
-    {
-      if (lval != NULL)
-       *lval = lval_memory;
-      if (regnum == SP_REGNUM)
-       {
-         if (raw_buffer != NULL)
-           {
-             /* Put it back in target format.  */
-             store_address (raw_buffer, REGISTER_RAW_SIZE (regnum),
-                            (LONGEST) addr);
-           }
-         if (addrp != NULL)
-           *addrp = 0;
-         return;
-       }
-      if (raw_buffer != NULL)
-       target_read_memory (addr, raw_buffer, REGISTER_RAW_SIZE (regnum));
-    }
-  else
-    {
-      if (lval != NULL)
-       *lval = lval_register;
-      addr = REGISTER_BYTE (regnum);
-      if (raw_buffer != NULL)
-       read_register_gen (regnum, raw_buffer);
-    }
-  if (addrp != NULL)
-    *addrp = addr;
-}
-
 /* Code to initialize the addresses of the saved registers of frame described
    by FRAME_INFO.  This includes special registers such as pc and fp saved in
    special ways in the stack frame.  sp is even more special: the address we
@@ -614,8 +569,6 @@ ns32k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_frame_args_skip (gdbarch, 8);
 
-  set_gdbarch_get_saved_register (gdbarch, ns32k_get_saved_register);
-
   set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
 
   /* Return value info */
index 46dce5a6cd4c38b07bddcc9093581a88c9dfd592..c0a650cff92dfd2f8f7b0d660317c8dd2eb737b8 100644 (file)
@@ -45,7 +45,6 @@ static gdbarch_frame_saved_pc_ftype vax_frame_saved_pc;
 static gdbarch_frame_args_address_ftype vax_frame_args_address;
 static gdbarch_frame_locals_address_ftype vax_frame_locals_address;
 static gdbarch_frame_init_saved_regs_ftype vax_frame_init_saved_regs;
-static gdbarch_get_saved_register_ftype vax_get_saved_register;
 
 static gdbarch_store_struct_return_ftype vax_store_struct_return;
 static gdbarch_deprecated_extract_return_value_ftype vax_extract_return_value;
@@ -124,51 +123,6 @@ vax_register_virtual_type (int regno)
   return (builtin_type_int);
 }
 \f
-static void
-vax_get_saved_register (char *raw_buffer, int *optimized, CORE_ADDR *addrp,
-                        struct frame_info *frame, int regnum,
-                        enum lval_type *lval)
-{
-  CORE_ADDR addr;
-
-  if (!target_has_registers)
-    error ("No registers.");
-
-  /* Normal systems don't optimize out things with register numbers.  */
-  if (optimized != NULL)
-    *optimized = 0;
-  addr = find_saved_register (frame, regnum);
-  if (addr != 0)
-    {
-      if (lval != NULL)
-       *lval = lval_memory;
-      if (regnum == SP_REGNUM)
-       {
-         if (raw_buffer != NULL)
-           {
-             /* Put it back in target format.  */
-             store_address (raw_buffer, REGISTER_RAW_SIZE (regnum),
-                            (LONGEST) addr);
-           }
-         if (addrp != NULL)
-           *addrp = 0;
-         return;
-       }
-      if (raw_buffer != NULL)
-       target_read_memory (addr, raw_buffer, REGISTER_RAW_SIZE (regnum));
-    }
-  else
-    {
-      if (lval != NULL)
-       *lval = lval_register;
-      addr = REGISTER_BYTE (regnum);
-      if (raw_buffer != NULL)
-       read_register_gen (regnum, raw_buffer);
-    }
-  if (addrp != NULL)
-    *addrp = addr;
-}
-
 static void
 vax_frame_init_saved_regs (struct frame_info *frame)
 {
@@ -691,8 +645,6 @@ vax_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
 
   set_gdbarch_frame_args_skip (gdbarch, 4);
 
-  set_gdbarch_get_saved_register (gdbarch, vax_get_saved_register);
-
   set_gdbarch_inner_than (gdbarch, core_addr_lessthan);
 
   /* Return value info */