1999-04-16 03:35:26 +02:00
|
|
|
|
/* Functions specific to running gdb native on a SPARC running SunOS4.
|
2003-02-07 05:49:34 +01:00
|
|
|
|
|
|
|
|
|
Copyright 1989, 1992, 1993, 1994, 1996, 1997, 1998, 1999, 2000,
|
|
|
|
|
2001, 2002, 2003 Free Software Foundation, Inc.
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
This file is part of GDB.
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
This program is free software; you can redistribute it and/or modify
|
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
|
the Free Software Foundation; either version 2 of the License, or
|
|
|
|
|
(at your option) any later version.
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
GNU General Public License for more details.
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
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. */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
#include "defs.h"
|
|
|
|
|
#include "inferior.h"
|
|
|
|
|
#include "target.h"
|
|
|
|
|
#include "gdbcore.h"
|
2001-03-01 02:39:22 +01:00
|
|
|
|
#include "regcache.h"
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
2003-07-07 17:56:08 +02:00
|
|
|
|
#include "sparc-tdep.h"
|
|
|
|
|
|
2002-03-21 03:03:13 +01:00
|
|
|
|
#ifdef HAVE_SYS_PARAM_H
|
|
|
|
|
#include <sys/param.h>
|
|
|
|
|
#endif
|
1999-04-16 03:35:26 +02:00
|
|
|
|
#include <signal.h>
|
|
|
|
|
#include <sys/ptrace.h>
|
2003-02-07 05:49:34 +01:00
|
|
|
|
#include "gdb_wait.h"
|
1999-04-16 03:35:26 +02:00
|
|
|
|
#ifdef __linux__
|
|
|
|
|
#include <asm/reg.h>
|
|
|
|
|
#else
|
|
|
|
|
#include <machine/reg.h>
|
|
|
|
|
#endif
|
|
|
|
|
#include <sys/user.h>
|
|
|
|
|
|
|
|
|
|
/* We don't store all registers immediately when requested, since they
|
|
|
|
|
get sent over in large chunks anyway. Instead, we accumulate most
|
|
|
|
|
of the changes and send them over once. "deferred_stores" keeps
|
|
|
|
|
track of which sets of registers we have locally-changed copies of,
|
|
|
|
|
so we only need send the groups that have changed. */
|
|
|
|
|
|
|
|
|
|
#define INT_REGS 1
|
|
|
|
|
#define STACK_REGS 2
|
|
|
|
|
#define FP_REGS 4
|
|
|
|
|
|
|
|
|
|
/* Fetch one or more registers from the inferior. REGNO == -1 to get
|
|
|
|
|
them all. We actually fetch more than requested, when convenient,
|
|
|
|
|
marking them as valid so we won't fetch them again. */
|
|
|
|
|
|
|
|
|
|
void
|
2000-07-30 03:48:28 +02:00
|
|
|
|
fetch_inferior_registers (int regno)
|
1999-04-16 03:35:26 +02:00
|
|
|
|
{
|
|
|
|
|
struct regs inferior_registers;
|
|
|
|
|
struct fp_status inferior_fp_registers;
|
|
|
|
|
int i;
|
2002-12-04 04:20:30 +01:00
|
|
|
|
int fetch_pid;
|
|
|
|
|
|
|
|
|
|
/* NOTE: cagney/2002-12-03: This code assumes that the currently
|
|
|
|
|
selected light weight processes' registers can be written
|
|
|
|
|
directly into the selected thread's register cache. This works
|
|
|
|
|
fine when given an 1:1 LWP:thread model (such as found on
|
|
|
|
|
GNU/Linux) but will, likely, have problems when used on an N:1
|
|
|
|
|
(userland threads) or N:M (userland multiple LWP) model. In the
|
|
|
|
|
case of the latter two, the LWP's registers do not necessarily
|
|
|
|
|
belong to the selected thread (the LWP could be in the middle of
|
|
|
|
|
executing the thread switch code).
|
|
|
|
|
|
|
|
|
|
These functions should instead be paramaterized with an explicit
|
|
|
|
|
object (struct regcache, struct thread_info?) into which the LWPs
|
|
|
|
|
registers can be written. */
|
|
|
|
|
|
|
|
|
|
fetch_pid = TIDGET (inferior_ptid);
|
|
|
|
|
if (fetch_pid == 0)
|
|
|
|
|
fetch_pid = PIDGET (inferior_ptid);
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
/* We should never be called with deferred stores, because a prerequisite
|
|
|
|
|
for writing regs is to have fetched them all (PREPARE_TO_STORE), sigh. */
|
1999-07-07 22:19:36 +02:00
|
|
|
|
if (deferred_stores)
|
2001-02-25 05:45:12 +01:00
|
|
|
|
internal_error (__FILE__, __LINE__, "failed internal consistency check");
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
DO_DEFERRED_STORES;
|
|
|
|
|
|
|
|
|
|
/* Global and Out regs are fetched directly, as well as the control
|
|
|
|
|
registers. If we're getting one of the in or local regs,
|
|
|
|
|
and the stack pointer has not yet been fetched,
|
|
|
|
|
we have to do that first, since they're found in memory relative
|
|
|
|
|
to the stack pointer. */
|
1999-07-07 22:19:36 +02:00
|
|
|
|
if (regno < O7_REGNUM /* including -1 */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|| regno >= Y_REGNUM
|
2002-11-07 03:40:28 +01:00
|
|
|
|
|| (!deprecated_register_valid[SP_REGNUM] && regno < I7_REGNUM))
|
1999-04-16 03:35:26 +02:00
|
|
|
|
{
|
2002-12-04 04:20:30 +01:00
|
|
|
|
if (0 != ptrace (PTRACE_GETREGS, fetch_pid,
|
1999-07-07 22:19:36 +02:00
|
|
|
|
(PTRACE_ARG3_TYPE) & inferior_registers, 0))
|
|
|
|
|
perror ("ptrace_getregs");
|
|
|
|
|
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
deprecated_registers[DEPRECATED_REGISTER_BYTE (0)] = 0;
|
|
|
|
|
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (1)],
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
&inferior_registers.r_g1, 15 * DEPRECATED_REGISTER_RAW_SIZE (G0_REGNUM));
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (PS_REGNUM)]
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
= inferior_registers.r_ps;
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (PC_REGNUM)]
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
= inferior_registers.r_pc;
|
2003-09-17 17:42:21 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (DEPRECATED_NPC_REGNUM)]
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
= inferior_registers.r_npc;
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (Y_REGNUM)] = inferior_registers.r_y;
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
for (i = G0_REGNUM; i <= O7_REGNUM; i++)
|
2002-11-07 03:40:28 +01:00
|
|
|
|
deprecated_register_valid[i] = 1;
|
|
|
|
|
deprecated_register_valid[Y_REGNUM] = 1;
|
|
|
|
|
deprecated_register_valid[PS_REGNUM] = 1;
|
|
|
|
|
deprecated_register_valid[PC_REGNUM] = 1;
|
2003-09-17 17:42:21 +02:00
|
|
|
|
deprecated_register_valid[DEPRECATED_NPC_REGNUM] = 1;
|
1999-04-16 03:35:26 +02:00
|
|
|
|
/* If we don't set these valid, read_register_bytes() rereads
|
1999-07-07 22:19:36 +02:00
|
|
|
|
all the regs every time it is called! FIXME. */
|
2002-11-07 03:40:28 +01:00
|
|
|
|
deprecated_register_valid[WIM_REGNUM] = 1; /* Not true yet, FIXME */
|
|
|
|
|
deprecated_register_valid[TBR_REGNUM] = 1; /* Not true yet, FIXME */
|
|
|
|
|
deprecated_register_valid[CPS_REGNUM] = 1; /* Not true yet, FIXME */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* Floating point registers */
|
|
|
|
|
if (regno == -1 ||
|
|
|
|
|
regno == FPS_REGNUM ||
|
|
|
|
|
(regno >= FP0_REGNUM && regno <= FP0_REGNUM + 31))
|
|
|
|
|
{
|
2002-12-04 04:20:30 +01:00
|
|
|
|
if (0 != ptrace (PTRACE_GETFPREGS, fetch_pid,
|
1999-07-07 22:19:36 +02:00
|
|
|
|
(PTRACE_ARG3_TYPE) & inferior_fp_registers,
|
1999-04-16 03:35:26 +02:00
|
|
|
|
0))
|
1999-07-07 22:19:36 +02:00
|
|
|
|
perror ("ptrace_getfpregs");
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
&inferior_fp_registers, sizeof inferior_fp_registers.fpu_fr);
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FPS_REGNUM)],
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
&inferior_fp_registers.Fpu_fsr, sizeof (FPU_FSR_TYPE));
|
1999-07-07 22:19:36 +02:00
|
|
|
|
for (i = FP0_REGNUM; i <= FP0_REGNUM + 31; i++)
|
2002-11-07 03:40:28 +01:00
|
|
|
|
deprecated_register_valid[i] = 1;
|
|
|
|
|
deprecated_register_valid[FPS_REGNUM] = 1;
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* These regs are saved on the stack by the kernel. Only read them
|
|
|
|
|
all (16 ptrace calls!) if we really need them. */
|
|
|
|
|
if (regno == -1)
|
|
|
|
|
{
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
CORE_ADDR sp = *(unsigned int *) & deprecated_registers[DEPRECATED_REGISTER_BYTE (SP_REGNUM)];
|
|
|
|
|
target_read_memory (sp, &deprecated_registers[DEPRECATED_REGISTER_BYTE (L0_REGNUM)],
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
16 * DEPRECATED_REGISTER_RAW_SIZE (L0_REGNUM));
|
1999-04-16 03:35:26 +02:00
|
|
|
|
for (i = L0_REGNUM; i <= I7_REGNUM; i++)
|
2002-11-07 03:40:28 +01:00
|
|
|
|
deprecated_register_valid[i] = 1;
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
else if (regno >= L0_REGNUM && regno <= I7_REGNUM)
|
|
|
|
|
{
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
CORE_ADDR sp = *(unsigned int *) & deprecated_registers[DEPRECATED_REGISTER_BYTE (SP_REGNUM)];
|
|
|
|
|
i = DEPRECATED_REGISTER_BYTE (regno);
|
2002-11-07 03:40:28 +01:00
|
|
|
|
if (deprecated_register_valid[regno])
|
1999-07-07 22:19:36 +02:00
|
|
|
|
printf_unfiltered ("register %d valid and read\n", regno);
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
target_read_memory (sp + i - DEPRECATED_REGISTER_BYTE (L0_REGNUM),
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
&deprecated_registers[i], DEPRECATED_REGISTER_RAW_SIZE (regno));
|
2002-11-07 03:40:28 +01:00
|
|
|
|
deprecated_register_valid[regno] = 1;
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* Store our register values back into the inferior.
|
|
|
|
|
If REGNO is -1, do this for all registers.
|
|
|
|
|
Otherwise, REGNO specifies which register (so we can save time). */
|
|
|
|
|
|
|
|
|
|
void
|
2000-07-30 03:48:28 +02:00
|
|
|
|
store_inferior_registers (int regno)
|
1999-04-16 03:35:26 +02:00
|
|
|
|
{
|
|
|
|
|
struct regs inferior_registers;
|
|
|
|
|
struct fp_status inferior_fp_registers;
|
|
|
|
|
int wanna_store = INT_REGS + STACK_REGS + FP_REGS;
|
2002-12-04 04:20:30 +01:00
|
|
|
|
int store_pid;
|
|
|
|
|
|
|
|
|
|
/* NOTE: cagney/2002-12-02: See comment in fetch_inferior_registers
|
|
|
|
|
about threaded assumptions. */
|
|
|
|
|
store_pid = TIDGET (inferior_ptid);
|
|
|
|
|
if (store_pid == 0)
|
|
|
|
|
store_pid = PIDGET (inferior_ptid);
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
/* First decide which pieces of machine-state we need to modify.
|
|
|
|
|
Default for regno == -1 case is all pieces. */
|
|
|
|
|
if (regno >= 0)
|
2002-04-21 07:34:06 +02:00
|
|
|
|
{
|
|
|
|
|
if (FP0_REGNUM <= regno && regno < FP0_REGNUM + 32)
|
|
|
|
|
{
|
1999-04-16 03:35:26 +02:00
|
|
|
|
wanna_store = FP_REGS;
|
2002-04-21 07:34:06 +02:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if (regno == SP_REGNUM)
|
|
|
|
|
wanna_store = INT_REGS + STACK_REGS;
|
|
|
|
|
else if (regno < L0_REGNUM || regno > I7_REGNUM)
|
|
|
|
|
wanna_store = INT_REGS;
|
|
|
|
|
else if (regno == FPS_REGNUM)
|
|
|
|
|
wanna_store = FP_REGS;
|
|
|
|
|
else
|
|
|
|
|
wanna_store = STACK_REGS;
|
|
|
|
|
}
|
|
|
|
|
}
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
/* See if we're forcing the stores to happen now, or deferring. */
|
|
|
|
|
if (regno == -2)
|
|
|
|
|
{
|
|
|
|
|
wanna_store = deferred_stores;
|
|
|
|
|
deferred_stores = 0;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if (wanna_store == STACK_REGS)
|
|
|
|
|
{
|
|
|
|
|
/* Fall through and just store one stack reg. If we deferred
|
|
|
|
|
it, we'd have to store them all, or remember more info. */
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
deferred_stores |= wanna_store;
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (wanna_store & STACK_REGS)
|
|
|
|
|
{
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
CORE_ADDR sp = *(unsigned int *) & deprecated_registers[DEPRECATED_REGISTER_BYTE (SP_REGNUM)];
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
if (regno < 0 || regno == SP_REGNUM)
|
|
|
|
|
{
|
2002-11-07 03:40:28 +01:00
|
|
|
|
if (!deprecated_register_valid[L0_REGNUM + 5])
|
2001-02-25 05:45:12 +01:00
|
|
|
|
internal_error (__FILE__, __LINE__, "failed internal consistency check");
|
1999-07-07 22:19:36 +02:00
|
|
|
|
target_write_memory (sp,
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
&deprecated_registers[DEPRECATED_REGISTER_BYTE (L0_REGNUM)],
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
16 * DEPRECATED_REGISTER_RAW_SIZE (L0_REGNUM));
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2002-11-07 03:40:28 +01:00
|
|
|
|
if (!deprecated_register_valid[regno])
|
2001-02-25 05:45:12 +01:00
|
|
|
|
internal_error (__FILE__, __LINE__, "failed internal consistency check");
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
target_write_memory (sp + DEPRECATED_REGISTER_BYTE (regno) - DEPRECATED_REGISTER_BYTE (L0_REGNUM),
|
|
|
|
|
&deprecated_registers[DEPRECATED_REGISTER_BYTE (regno)],
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
DEPRECATED_REGISTER_RAW_SIZE (regno));
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
1999-07-07 22:19:36 +02:00
|
|
|
|
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (wanna_store & INT_REGS)
|
|
|
|
|
{
|
2002-11-07 03:40:28 +01:00
|
|
|
|
if (!deprecated_register_valid[G1_REGNUM])
|
2001-02-25 05:45:12 +01:00
|
|
|
|
internal_error (__FILE__, __LINE__, "failed internal consistency check");
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
memcpy (&inferior_registers.r_g1,
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
&deprecated_registers[DEPRECATED_REGISTER_BYTE (G1_REGNUM)],
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
15 * DEPRECATED_REGISTER_RAW_SIZE (G1_REGNUM));
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
inferior_registers.r_ps =
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (PS_REGNUM)];
|
1999-04-16 03:35:26 +02:00
|
|
|
|
inferior_registers.r_pc =
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (PC_REGNUM)];
|
1999-04-16 03:35:26 +02:00
|
|
|
|
inferior_registers.r_npc =
|
2003-09-17 17:42:21 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (DEPRECATED_NPC_REGNUM)];
|
1999-04-16 03:35:26 +02:00
|
|
|
|
inferior_registers.r_y =
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (Y_REGNUM)];
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
2002-12-04 04:20:30 +01:00
|
|
|
|
if (0 != ptrace (PTRACE_SETREGS, store_pid,
|
1999-07-07 22:19:36 +02:00
|
|
|
|
(PTRACE_ARG3_TYPE) & inferior_registers, 0))
|
|
|
|
|
perror ("ptrace_setregs");
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (wanna_store & FP_REGS)
|
|
|
|
|
{
|
2002-11-07 03:40:28 +01:00
|
|
|
|
if (!deprecated_register_valid[FP0_REGNUM + 9])
|
2001-02-25 05:45:12 +01:00
|
|
|
|
internal_error (__FILE__, __LINE__, "failed internal consistency check");
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
memcpy (&inferior_fp_registers,
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
1999-04-16 03:35:26 +02:00
|
|
|
|
sizeof inferior_fp_registers.fpu_fr);
|
1999-07-07 22:19:36 +02:00
|
|
|
|
memcpy (&inferior_fp_registers.Fpu_fsr,
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
&deprecated_registers[DEPRECATED_REGISTER_BYTE (FPS_REGNUM)],
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
sizeof (FPU_FSR_TYPE));
|
1999-04-16 03:35:26 +02:00
|
|
|
|
if (0 !=
|
2002-12-04 04:20:30 +01:00
|
|
|
|
ptrace (PTRACE_SETFPREGS, store_pid,
|
1999-07-07 22:19:36 +02:00
|
|
|
|
(PTRACE_ARG3_TYPE) & inferior_fp_registers, 0))
|
|
|
|
|
perror ("ptrace_setfpregs");
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2000-10-23 05:21:06 +02:00
|
|
|
|
/* Provide registers to GDB from a core file.
|
|
|
|
|
|
|
|
|
|
CORE_REG_SECT points to an array of bytes, which are the contents
|
|
|
|
|
of a `note' from a core file which BFD thinks might contain
|
|
|
|
|
register contents. CORE_REG_SIZE is its size.
|
|
|
|
|
|
|
|
|
|
WHICH says which register set corelow suspects this is:
|
|
|
|
|
0 --- the general-purpose register set
|
|
|
|
|
2 --- the floating-point register set
|
|
|
|
|
|
|
|
|
|
IGNORE is unused. */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
static void
|
2000-10-23 05:21:06 +02:00
|
|
|
|
fetch_core_registers (char *core_reg_sect, unsigned core_reg_size,
|
|
|
|
|
int which, CORE_ADDR ignore)
|
1999-04-16 03:35:26 +02:00
|
|
|
|
{
|
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
if (which == 0)
|
|
|
|
|
{
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
/* Integer registers */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
#define gregs ((struct regs *)core_reg_sect)
|
1999-07-07 22:19:36 +02:00
|
|
|
|
/* G0 *always* holds 0. */
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (0)] = 0;
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
/* The globals and output registers. */
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (G1_REGNUM)], &gregs->r_g1,
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
15 * DEPRECATED_REGISTER_RAW_SIZE (G1_REGNUM));
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (PS_REGNUM)] = gregs->r_ps;
|
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (PC_REGNUM)] = gregs->r_pc;
|
2003-09-17 17:42:21 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (DEPRECATED_NPC_REGNUM)] = gregs->r_npc;
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
*(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (Y_REGNUM)] = gregs->r_y;
|
1999-07-07 22:19:36 +02:00
|
|
|
|
|
|
|
|
|
/* My best guess at where to get the locals and input
|
|
|
|
|
registers is exactly where they usually are, right above
|
|
|
|
|
the stack pointer. If the core dump was caused by a bus error
|
|
|
|
|
from blowing away the stack pointer (as is possible) then this
|
|
|
|
|
won't work, but it's worth the try. */
|
|
|
|
|
{
|
|
|
|
|
int sp;
|
|
|
|
|
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
sp = *(int *) &deprecated_registers[DEPRECATED_REGISTER_BYTE (SP_REGNUM)];
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
if (0 != target_read_memory (sp,
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
&deprecated_registers[DEPRECATED_REGISTER_BYTE (L0_REGNUM)],
|
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_RAW_SIZE): Rename
REGISTER_RAW_SIZE.
* gdbarch.h, gdbarch.c: Re-generate.
* aix-thread.c, alpha-tdep.h, arm-tdep.c, core-sol2.c: Update.
* cris-tdep.c, dve3900-rom.c, findvar.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, ia64-tdep.c, infcmd.c, infptrace.c: Update.
* infrun.c, irix5-nat.c, lynx-nat.c, mips-linux-tdep.c: Update.
* mips-nat.c, mips-tdep.c, mipsv4-nat.c, mn10300-tdep.c: Update.
* monitor.c, ns32k-tdep.c, ppc-linux-nat.c, regcache.c: Update.
* remote-e7000.c, remote-mips.c, remote-sim.c: Update.
* remote-vxmips.c, remote-vxsparc.c, remote.c: Update.
* rom68k-rom.c, rs6000-nat.c, rs6000-tdep.c, s390-tdep.c: Update.
* sh64-tdep.c, sparc-nat.c, sparc-tdep.c, stack.c: Update.
* target.c, tracepoint.c, v850-tdep.c, v850ice.c, valops.c: Update.
* vax-tdep.c, vax-tdep.h, x86-64-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-delta68.h, config/m68k/tm-vx68.h: Update.
* config/sparc/tm-sparc.h, config/sparc/tm-sparclynx.h: Update.
2003-10-02 Andrew Cagney <cagney@redhat.com>
* gdbint.texinfo (Target Architecture Definition): Rename
REGISTER_RAW_SIZE to DEPRECATED_REGISTER_RAW_SIZE.
* gdb.texinfo (Packets, Stop Reply Packets): Ditto.
* gdbint.texinfo (Target Architecture Definition): Rename
2003-10-02 Andrew Cagney <cagney@redhat.com>
* mi-main.c: Rename REGISTER_RAW_SIZE to
DEPRECATED_REGISTER_RAW_SIZE.
2003-10-02 22:28:31 +02:00
|
|
|
|
16 * DEPRECATED_REGISTER_RAW_SIZE (L0_REGNUM)))
|
1999-07-07 22:19:36 +02:00
|
|
|
|
{
|
|
|
|
|
/* fprintf_unfiltered so user can still use gdb */
|
|
|
|
|
fprintf_unfiltered (gdb_stderr,
|
|
|
|
|
"Couldn't read input and local registers from core file\n");
|
|
|
|
|
}
|
|
|
|
|
}
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
1999-07-07 22:19:36 +02:00
|
|
|
|
else if (which == 2)
|
|
|
|
|
{
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
/* Floating point registers */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
|
|
|
|
|
#define fpuregs ((struct fpu *) core_reg_sect)
|
1999-07-07 22:19:36 +02:00
|
|
|
|
if (core_reg_size >= sizeof (struct fpu))
|
|
|
|
|
{
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
fpuregs->fpu_regs, sizeof (fpuregs->fpu_regs));
|
2003-09-17 Andrew Cagney <cagney@redhat.com>
* gdbarch.sh (DEPRECATED_REGISTER_BYTE): Rename REGISTER_BYTE.
* gdbarch.h, gdbarch.c: Regenerate.
* arm-linux-tdep.c, core-sol2.c, cris-tdep.c: Update.
* d10v-tdep.c, frame.c: Update.
* hppa-tdep.c, hppab-nat.c, hppah-nat.c, hppam3-nat.c: Update.
* hpux-thread.c, i386gnu-nat.c, ia64-aix-nat.c: Update.
* ia64-linux-nat.c, irix5-nat.c, lynx-nat.c, m68knbsd-nat.c: Update.
* mcore-tdep.c, mips-linux-tdep.c, mips-tdep.c: Update.
* mipsv4-nat.c, mn10300-tdep.c, ns32k-tdep.c: Update.
* ns32knbsd-nat.c, ppc-bdm.c, regcache.c, remote-sds.c: Update.
* remote-vx68.c, remote-vxmips.c, remote-vxsparc.c: Update.
* remote.c, rs6000-tdep.c, s390-tdep.c, sh64-tdep.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, v850-tdep.c: Update.
* v850ice.c, vax-tdep.c, xstormy16-tdep.c: Update.
* config/m68k/tm-cisco.h, config/m68k/tm-delta68.h: Update.
* config/pa/nm-hppah.h: Update.
2003-09-17 Andrew Cagney <cagney@redhat.com>
* mi/mi-main.c: Rename REGISTER_BYTE to DEPRECATED_REGISTER_BYTE.
2003-09-17 16:24:31 +02:00
|
|
|
|
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FPS_REGNUM)],
|
2002-11-14 Andrew Cagney <ac131313@redhat.com>
* regcache.h (deprecated_registers): Rename registers.
* a68v-nat.c, alpha-nat.c, arch-utils.c, core-sol2.c: Update.
* hp300ux-nat.c, hppab-nat.c, hppah-nat.c: Update.
* hppam3-nat.c, hpux-thread.c, i386gnu-nat.c: Update.
* ia64-aix-nat.c, ia64-linux-nat.c, ia64-tdep.c: Update.
* irix4-nat.c, irix5-nat.c, lynx-nat.c, m68k-tdep.c: Update.
* m68knbsd-nat.c, mips-linux-tdep.c, mipsm3-nat.c: Update.
* mipsv4-nat.c, ns32knbsd-nat.c, ppc-bdm.c: Update.
* ppc-sysv-tdep.c, ptx4-nat.c, regcache.c, remote-es.c: Update.
* remote-sds.c, remote-vx68.c, remote-vxmips.c: Update.
* remote-vxsparc.c, rs6000-tdep.c, sol-thread.c: Update.
* sparc-nat.c, sparc-tdep.c, sun3-nat.c, symm-nat.c: Update.
* v850ice.c: Update.
2002-11-14 21:37:29 +01:00
|
|
|
|
&fpuregs->fpu_fsr, sizeof (FPU_FSR_TYPE));
|
1999-07-07 22:19:36 +02:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
fprintf_unfiltered (gdb_stderr, "Couldn't read float regs from core file\n");
|
|
|
|
|
}
|
1999-04-16 03:35:26 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int
|
2000-07-30 03:48:28 +02:00
|
|
|
|
kernel_u_size (void)
|
1999-04-16 03:35:26 +02:00
|
|
|
|
{
|
|
|
|
|
return (sizeof (struct user));
|
|
|
|
|
}
|
|
|
|
|
|
1999-07-07 22:19:36 +02:00
|
|
|
|
|
1999-04-16 03:35:26 +02:00
|
|
|
|
/* Register that we are able to handle sparc core file formats.
|
|
|
|
|
FIXME: is this really bfd_target_unknown_flavour? */
|
|
|
|
|
|
|
|
|
|
static struct core_fns sparc_core_fns =
|
|
|
|
|
{
|
1999-10-06 01:13:56 +02:00
|
|
|
|
bfd_target_unknown_flavour, /* core_flavour */
|
|
|
|
|
default_check_format, /* check_format */
|
|
|
|
|
default_core_sniffer, /* core_sniffer */
|
|
|
|
|
fetch_core_registers, /* core_read_registers */
|
|
|
|
|
NULL /* next */
|
1999-04-16 03:35:26 +02:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
void
|
2000-07-30 03:48:28 +02:00
|
|
|
|
_initialize_core_sparc (void)
|
1999-04-16 03:35:26 +02:00
|
|
|
|
{
|
|
|
|
|
add_core_fns (&sparc_core_fns);
|
|
|
|
|
}
|