Call cooked_read in ppu2spu_prev_register
[binutils-gdb.git] / gdb / corelow.c
index ac7226821c291172aab7350d6790c6d46c5ea5f6..3a5256cb1704ecb653579af8404f66e84c96bab5 100644 (file)
@@ -1,6 +1,6 @@
 /* Core dump and executable file functions below target vector, for GDB.
 
-   Copyright (C) 1986-2017 Free Software Foundation, Inc.
+   Copyright (C) 1986-2018 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -88,8 +88,6 @@ static void add_to_thread_list (bfd *, asection *, void *);
 
 static void init_core_ops (void);
 
-void _initialize_corelow (void);
-
 static struct target_ops core_ops;
 
 /* An arbitrary identifier for the core inferior.  */
@@ -274,7 +272,6 @@ core_open (const char *arg, int from_tty)
   const char *p;
   int siggy;
   struct cleanup *old_chain;
-  char *temp;
   int scratch_chan;
   int flags;
 
@@ -605,7 +602,7 @@ get_core_registers (struct target_ops *ops,
       return;
     }
 
-  gdbarch = get_regcache_arch (regcache);
+  gdbarch = regcache->arch ();
   if (gdbarch_iterate_over_regset_sections_p (gdbarch))
     gdbarch_iterate_over_regset_sections (gdbarch,
                                          get_core_registers_cb,
@@ -619,7 +616,7 @@ get_core_registers (struct target_ops *ops,
     }
 
   /* Mark all registers not found in the core as unavailable.  */
-  for (i = 0; i < gdbarch_num_regs (get_regcache_arch (regcache)); i++)
+  for (i = 0; i < gdbarch_num_regs (regcache->arch ()); i++)
     if (regcache_register_status (regcache, i) == REG_UNKNOWN)
       regcache_raw_supply (regcache, i, NULL);
 }