2004-07-28 Andrew Cagney <cagney@gnu.org>
[platform/upstream/binutils.git] / gdb / ppcobsd-tdep.c
index 641f372..49a8601 100644 (file)
@@ -47,12 +47,16 @@ ppcobsd_supply_gregset (const struct regset *regset,
                        struct regcache *regcache, int regnum,
                        const void *gregs, size_t len)
 {
-  /* FIXME: jimb/2004-05-05: Some PPC variants don't have
-     floating-point registers.  For such variants,
-     tdep->ppc_fp0_regnum and tdep->ppc_fpscr_regnum will be -1.  I
-     don't think OpenBSD runs on any of those chips, but we can at
-     least make sure that if someone tries it, they'll get a proper
-     notification.  */
+  /* FIXME: jimb/2004-05-05: Some PPC variants don't have floating
+     point registers.  Traditionally, GDB's register set has still
+     listed the floating point registers for such machines, so this
+     code is harmless.  However, the new E500 port actually omits the
+     floating point registers entirely from the register set --- they
+     don't even have register numbers assigned to them.
+
+     It's not clear to me how best to update this code, so this assert
+     will alert the first person to encounter the OpenBSD/E500
+     combination to the problem.  */
   gdb_assert (ppc_floating_point_unit_p (current_gdbarch));
 
   ppc_supply_gregset (regset, regcache, regnum, gregs, len);
@@ -69,12 +73,16 @@ ppcobsd_collect_gregset (const struct regset *regset,
                         const struct regcache *regcache, int regnum,
                         void *gregs, size_t len)
 {
-  /* FIXME: jimb/2004-05-05: Some PPC variants don't have
-     floating-point registers.  For such variants,
-     tdep->ppc_fp0_regnum and tdep->ppc_fpscr_regnum will be -1.  I
-     don't think OpenBSD runs on any of those chips, but we can at
-     least make sure that if someone tries it, they'll get a proper
-     notification.  */
+  /* FIXME: jimb/2004-05-05: Some PPC variants don't have floating
+     point registers.  Traditionally, GDB's register set has still
+     listed the floating point registers for such machines, so this
+     code is harmless.  However, the new E500 port actually omits the
+     floating point registers entirely from the register set --- they
+     don't even have register numbers assigned to them.
+
+     It's not clear to me how best to update this code, so this assert
+     will alert the first person to encounter the OpenBSD/E500
+     combination to the problem.  */
   gdb_assert (ppc_floating_point_unit_p (current_gdbarch));
 
   ppc_collect_gregset (regset, regcache, regnum, gregs, len);