* spu-tdep.c: Update for unwinder changes.
[deliverable/binutils-gdb.git] / gdb / arch-utils.c
index c75e10bb8ed5bc00eca45d0e343a7b515f7b4ed7..2c8b34b4accdb1dfc505ec7144a6f7f23463f1db 100644 (file)
@@ -1,7 +1,7 @@
 /* Dynamic architecture support for GDB, the GNU debugger.
 
-   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
-   Free Software Foundation, Inc.
+   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
+   2008 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
 
 
 int
-legacy_register_sim_regno (int regnum)
+legacy_register_sim_regno (struct gdbarch *gdbarch, int regnum)
 {
   /* Only makes sense to supply raw registers.  */
-  gdb_assert (regnum >= 0 && regnum < gdbarch_num_regs (current_gdbarch));
+  gdb_assert (regnum >= 0 && regnum < gdbarch_num_regs (gdbarch));
   /* NOTE: cagney/2002-05-13: The old code did it this way and it is
      suspected that some GDB/SIM combinations may rely on this
      behavour.  The default should be one2one_register_sim_regno
      (below).  */
-  if (gdbarch_register_name (current_gdbarch, regnum) != NULL
-      && gdbarch_register_name (current_gdbarch, regnum)[0] != '\0')
+  if (gdbarch_register_name (gdbarch, regnum) != NULL
+      && gdbarch_register_name (gdbarch, regnum)[0] != '\0')
     return regnum;
   else
     return LEGACY_SIM_REGNO_IGNORE;
@@ -107,7 +107,7 @@ convert_from_func_ptr_addr_identity (struct gdbarch *gdbarch, CORE_ADDR addr,
 }
 
 int
-no_op_reg_to_regnum (int reg)
+no_op_reg_to_regnum (struct gdbarch *gdbarch, int reg)
 {
   return reg;
 }
@@ -125,7 +125,7 @@ default_coff_make_msymbol_special (int val, struct minimal_symbol *msym)
 }
 
 int
-cannot_register_not (int regnum)
+cannot_register_not (struct gdbarch *gdbarch, int regnum)
 {
   return 0;
 }
@@ -162,7 +162,8 @@ legacy_virtual_frame_pointer (struct gdbarch *gdbarch,
 
 \f
 int
-generic_convert_register_p (int regnum, struct type *type)
+generic_convert_register_p (struct gdbarch *gdbarch, int regnum,
+                           struct type *type)
 {
   return 0;
 }
@@ -453,8 +454,6 @@ gdbarch_update_p (struct gdbarch_info info)
 struct gdbarch *
 gdbarch_from_bfd (bfd *abfd)
 {
-  struct gdbarch *old_gdbarch = current_gdbarch;
-  struct gdbarch *new_gdbarch;
   struct gdbarch_info info;
 
   /* If we call gdbarch_find_by_info without filling in info.abfd,
This page took 0.024853 seconds and 4 git commands to generate.