Update FSF address.
[deliverable/binutils-gdb.git] / gdb / config / mips / nm-riscos.h
CommitLineData
3222c7d0
JK
1/* This program is free software; you can redistribute it and/or modify
2it under the terms of the GNU General Public License as published by
3the Free Software Foundation; either version 2 of the License, or
4(at your option) any later version.
5
6This program is distributed in the hope that it will be useful,
7but WITHOUT ANY WARRANTY; without even the implied warranty of
8MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9GNU General Public License for more details.
10
11You should have received a copy of the GNU General Public License
12along with this program; if not, write to the Free Software
6c9638b4 13Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
3222c7d0
JK
14
15/* MIPS running RISC/os 4.52C. */
16
17#define PCB_OFFSET(FIELD) ((int)&((struct user*)0)->u_pcb.FIELD)
18
d8a80e6d
ILT
19/* RISC/os 5.0 defines this in machparam.h. */
20#include <bsd43/machine/machparam.h>
e5307300
JK
21#define NBPG BSD43_NBPG
22#define UPAGES BSD43_UPAGES
3206db62
JK
23
24/* Where is this used? I don't see any uses in mips-nat.c, and I don't think
25 the uses in infptrace.c are used if FETCH_INFERIOR_REGISTERS is defined.
26 Does the compiler react badly to "extern CORE_ADDR kernel_u_addr" (even
27 if never referenced)? */
d8a80e6d 28#define KERNEL_U_ADDR BSD43_UADDR
e5307300 29
3222c7d0
JK
30#define REGISTER_U_ADDR(addr, blockend, regno) \
31 if (regno < FP0_REGNUM) \
32 addr = UPAGES*NBPG-EF_SIZE+4*((regno)+EF_AT-1); \
33 else if (regno < PC_REGNUM) \
34 addr = PCB_OFFSET(pcb_fpregs[0]) + 4*(regno-FP0_REGNUM); \
35 else if (regno == PS_REGNUM) \
36 addr = UPAGES*NBPG-EF_SIZE+4*EF_SR; \
37 else if (regno == BADVADDR_REGNUM) \
38 addr = UPAGES*NBPG-EF_SIZE+4*EF_BADVADDR; \
39 else if (regno == LO_REGNUM) \
40 addr = UPAGES*NBPG-EF_SIZE+4*EF_MDLO; \
41 else if (regno == HI_REGNUM) \
42 addr = UPAGES*NBPG-EF_SIZE+4*EF_MDHI; \
43 else if (regno == CAUSE_REGNUM) \
44 addr = UPAGES*NBPG-EF_SIZE+4*EF_CAUSE; \
45 else if (regno == PC_REGNUM) \
46 addr = UPAGES*NBPG-EF_SIZE+4*EF_EPC; \
47 else if (regno < FCRCS_REGNUM) \
48 addr = PCB_OFFSET(pcb_fpregs[0]) + 4*(regno-FP0_REGNUM); \
49 else if (regno == FCRCS_REGNUM) \
50 addr = PCB_OFFSET(pcb_fpc_csr); \
51 else if (regno == FCRIR_REGNUM) \
52 addr = PCB_OFFSET(pcb_fpc_eir); \
53 else \
54 addr = 0;
3222c7d0
JK
55
56#include "mips/nm-mips.h"
0abbc771
JK
57
58/* Override copies of {fetch,store}_inferior_registers in infptrace.c. */
59#define FETCH_INFERIOR_REGISTERS
This page took 0.11161 seconds and 4 git commands to generate.