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., 675 Mass Ave, Cambridge, MA 02139, USA. */
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "defs.h"
#include "inferior.h"
{
REG_N_OFFSET(r0), REG_N_OFFSET(r1), REG_N_OFFSET(r2), REG_N_OFFSET(r3),
REG_N_OFFSET(r4), REG_N_OFFSET(r5), REG_N_OFFSET(r6), REG_N_OFFSET(r7),
- REG_F_OFFSET(l0a), REG_F_OFFSET(l1a),REG_F_OFFSET(l2a),REG_F_OFFSET(l3a),
- REG_F_OFFSET(l4a), REG_F_OFFSET(l5a),REG_F_OFFSET(l6a),REG_F_OFFSET(l7a),
+ REG_F_OFFSET(l0a), REG_F_OFFSET(l0b),REG_F_OFFSET(l2a),REG_F_OFFSET(l2b),
+ REG_F_OFFSET(l4a), REG_F_OFFSET(l4b),REG_F_OFFSET(l6a),REG_F_OFFSET(l6b),
REG_N_OFFSET(sp), REG_N_OFFSET(fp), REG_N_OFFSET(pc), REG_N_OFFSET(psr),
REG_F_OFFSET(fsr),
- REG_F_OFFSET(l0a), REG_F_OFFSET(l2a),REG_F_OFFSET(l4a),REG_F_OFFSET(l6a)
- /* @@@ 532 has more double length floating point regs, not accessed currently */
+ REG_F_OFFSET(l0a), REG_F_OFFSET(l1a),REG_F_OFFSET(l2a),REG_F_OFFSET(l3a),
+ REG_F_OFFSET(l4a), REG_F_OFFSET(l5a),REG_F_OFFSET(l6a),REG_F_OFFSET(l7a),
};
+#define REG_ADDRESS(state,regnum) ((char *)(state)+reg_offset[regnum])
+
/* Fetch COUNT contiguous registers from thread STATE starting from REGNUM
* Caller knows that the regs handled in one transaction are of same size.
*/
#define FETCH_REGS(state, regnum, count) \
- bcopy ((char *)state+reg_offset[ regnum ], \
- ®isters[REGISTER_BYTE (regnum)], \
- count*sizeof (REGISTER_TYPE))
+ memcpy (®isters[REGISTER_BYTE (regnum)], \
+ (char *)state+reg_offset[ regnum ], \
+ count*REGISTER_SIZE)
/* Store COUNT contiguous registers to thread STATE starting from REGNUM */
#define STORE_REGS(state, regnum, count) \
- bcopy (®isters[REGISTER_BYTE (regnum)], \
- (char *)state+reg_offset[ regnum ], \
- count*sizeof (REGISTER_TYPE))
-\f
-/* 4.4 bfd support function */
-/* jtv@hut.fi: UNIMPLEMENTED!!!!! */
-
-void
-fetch_core_registers (core_regs, core_reg_size, which)
- char *core_regs;
- unsigned int core_reg_size;
- int which;
-{
- error ("Unimplemented routine fetch_core_registers called");
-}
+ memcpy ((char *)state+reg_offset[ regnum ], \
+ ®isters[REGISTER_BYTE (regnum)], \
+ count*REGISTER_SIZE)
\f
/*
* Fetch inferiors registers for gdb.
&stateCnt);
if (ret != KERN_SUCCESS)
- message ("fetch_inferior_registers: %s ",
+ warning ("fetch_inferior_registers: %s ",
mach_error_string (ret));
#if 0
/* It may be more effective to store validate all of them,
if (ret != KERN_SUCCESS)
{
- message ("store_inferior_registers (get): %s",
+ warning ("store_inferior_registers (get): %s",
mach_error_string (ret));
if (must_suspend_thread)
setup_thread (current_thread, 0);
NS532_COMBINED_STATE_COUNT);
if (ret != KERN_SUCCESS)
- message ("store_inferior_registers (set): %s",
+ warning ("store_inferior_registers (set): %s",
mach_error_string (ret));
if (must_suspend_thread)