* ada-lang.c (resolve_subexp): Correct arity of binary operators.
[deliverable/binutils-gdb.git] / gdb / mips64obsd-tdep.c
index 5feea36e15770955b25d9fac873738cb967be1ec..ddcd24dd5e869adbbca570e5f4d58b7981fc4696 100644 (file)
@@ -1,6 +1,6 @@
 /* Target-dependent code for OpenBSD/mips64.
 
-   Copyright 2004 Free Software Foundation, Inc.
+   Copyright (C) 2004, 2007 Free Software Foundation, Inc.
 
    This file is part of GDB.
 
@@ -16,8 +16,8 @@
 
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
+   Foundation, Inc., 51 Franklin Street, Fifth Floor,
+   Boston, MA 02110-1301, USA.  */
 
 #include "defs.h"
 #include "osabi.h"
@@ -91,23 +91,33 @@ mips64obsd_sigframe_init (const struct tramp_frame *self,
 
   /* We find the appropriate instance of `struct sigcontext' at a
      fixed offset in the signal frame.  */
-  sp = frame_unwind_register_signed (next_frame, MIPS_SP_REGNUM + NUM_REGS);
+  sp = frame_unwind_register_signed (next_frame,
+                                    MIPS_SP_REGNUM
+                                    + gdbarch_num_regs (current_gdbarch));
   sigcontext_addr = sp + 32;
 
   /* PC.  */
   regnum = mips_regnum (gdbarch)->pc;
-  trad_frame_set_reg_addr (cache, regnum + NUM_REGS, sigcontext_addr + 16);
+  trad_frame_set_reg_addr (cache,
+                          regnum + gdbarch_num_regs (current_gdbarch),
+                           sigcontext_addr + 16);
 
   /* GPRs.  */
   for (regnum = MIPS_AT_REGNUM, addr = sigcontext_addr + 32;
        regnum <= MIPS_RA_REGNUM; regnum++, addr += 8)
-    trad_frame_set_reg_addr (cache, regnum + NUM_REGS, addr);
+    trad_frame_set_reg_addr (cache,
+                            regnum + gdbarch_num_regs (current_gdbarch),
+                            addr);
 
   /* HI and LO.  */
   regnum = mips_regnum (gdbarch)->lo;
-  trad_frame_set_reg_addr (cache, regnum + NUM_REGS, sigcontext_addr + 280);
+  trad_frame_set_reg_addr (cache,
+                          regnum + gdbarch_num_regs (current_gdbarch),
+                          sigcontext_addr + 280);
   regnum = mips_regnum (gdbarch)->hi;
-  trad_frame_set_reg_addr (cache, regnum + NUM_REGS, sigcontext_addr + 288);
+  trad_frame_set_reg_addr (cache,
+                          regnum + gdbarch_num_regs (current_gdbarch),
+                          sigcontext_addr + 288);
 
   /* TODO: Handle the floating-point registers.  */
 
This page took 0.024619 seconds and 4 git commands to generate.