Commit | Line | Data |
---|---|---|
c906108c SS |
1 | /* Definitions to make GDB run on an encore under umax 4.2 |
2 | Copyright 1987, 1989, 1992 Free Software Foundation, Inc. | |
3 | ||
c5aa993b | 4 | This file is part of GDB. |
c906108c | 5 | |
c5aa993b JM |
6 | This program is free software; you can redistribute it and/or modify |
7 | it under the terms of the GNU General Public License as published by | |
8 | the Free Software Foundation; either version 2 of the License, or | |
9 | (at your option) any later version. | |
c906108c | 10 | |
c5aa993b JM |
11 | This program is distributed in the hope that it will be useful, |
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 | GNU General Public License for more details. | |
c906108c | 15 | |
c5aa993b JM |
16 | You should have received a copy of the GNU General Public License |
17 | along with this program; if not, write to the Free Software | |
18 | Foundation, Inc., 59 Temple Place - Suite 330, | |
19 | Boston, MA 02111-1307, USA. */ | |
c906108c SS |
20 | |
21 | /* Do implement the attach and detach commands... */ | |
22 | #define ATTACH_DETACH | |
23 | ||
24 | /* Offset of registers within u area. */ | |
25 | #define U_REGS_OFFSET 0 | |
26 | ||
27 | /* called from register_addr() -- blockend not used for now */ | |
28 | #define REGISTER_U_ADDR(addr, blockend, regno) \ | |
29 | { \ | |
30 | switch (regno) { \ | |
31 | case 0: case 1: case 2: case 3: case 4: case 5: case 6: case 7: \ | |
32 | addr = PU_R0 - (regno * sizeof (int)); break; \ | |
33 | case SP_REGNUM: \ | |
34 | addr = PU_SP; break; \ | |
35 | case PC_REGNUM: \ | |
36 | addr = PU_PC; break; \ | |
37 | case FP_REGNUM: \ | |
38 | addr = PU_FP; break; \ | |
39 | case PS_REGNUM: \ | |
40 | addr = PU_PSL; break; \ | |
41 | case FPS_REGNUM: \ | |
42 | addr = PU_FSR; break; \ | |
43 | case FP0_REGNUM + 0: case FP0_REGNUM + 1: \ | |
44 | case FP0_REGNUM + 2: case FP0_REGNUM + 3: \ | |
45 | case FP0_REGNUM + 4: case FP0_REGNUM + 5: \ | |
46 | case FP0_REGNUM + 6: case FP0_REGNUM + 7: \ | |
47 | addr = PU_F0 + (regno - FP0_REGNUM) * sizeof (float); break; \ | |
48 | case LP0_REGNUM + 0: case LP0_REGNUM + 1: \ | |
49 | case LP0_REGNUM + 2: case LP0_REGNUM + 3: \ | |
50 | addr = PU_F0 + (regno - LP0_REGNUM) * sizeof (double); break; \ | |
51 | default: \ | |
52 | printf ("bad argument to REGISTER_U_ADDR %d\n", regno); \ | |
53 | abort (); \ | |
54 | } \ | |
55 | } |