1 // OBSOLETE /* i80960-dependent portions of the RPC protocol
2 // OBSOLETE used with a VxWorks target
4 // OBSOLETE Contributed by Wind River Systems.
6 // OBSOLETE This file is part of GDB.
8 // OBSOLETE This program is free software; you can redistribute it and/or modify
9 // OBSOLETE it under the terms of the GNU General Public License as published by
10 // OBSOLETE the Free Software Foundation; either version 2 of the License, or
11 // OBSOLETE (at your option) any later version.
13 // OBSOLETE This program is distributed in the hope that it will be useful,
14 // OBSOLETE but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // OBSOLETE MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 // OBSOLETE GNU General Public License for more details.
18 // OBSOLETE You should have received a copy of the GNU General Public License
19 // OBSOLETE along with this program; if not, write to the Free Software
20 // OBSOLETE Foundation, Inc., 59 Temple Place - Suite 330,
21 // OBSOLETE Boston, MA 02111-1307, USA. */
23 // OBSOLETE #include <stdio.h>
24 // OBSOLETE #include "defs.h"
26 // OBSOLETE #include "vx-share/regPacket.h"
27 // OBSOLETE #include "frame.h"
28 // OBSOLETE #include "inferior.h"
29 // OBSOLETE #include "target.h"
30 // OBSOLETE #include "gdbcore.h"
31 // OBSOLETE #include "command.h"
32 // OBSOLETE #include "symtab.h"
33 // OBSOLETE #include "symfile.h" /* for struct complaint */
34 // OBSOLETE #include "regcache.h"
36 // OBSOLETE #include "gdb_string.h"
37 // OBSOLETE #include <errno.h>
38 // OBSOLETE #include <fcntl.h>
39 // OBSOLETE #include <sys/types.h>
40 // OBSOLETE #include <sys/time.h>
41 // OBSOLETE #include <sys/socket.h>
43 // OBSOLETE #ifdef _AIX /* IBM claims "void *malloc()" not char * */
44 // OBSOLETE #define malloc bogon_malloc
47 // OBSOLETE #include <rpc/rpc.h>
48 // OBSOLETE #include <sys/time.h> /* UTek's <rpc/rpc.h> doesn't #incl this */
49 // OBSOLETE #include <netdb.h>
50 // OBSOLETE #include "vx-share/ptrace.h"
51 // OBSOLETE #include "vx-share/xdr_ptrace.h"
52 // OBSOLETE #include "vx-share/xdr_ld.h"
53 // OBSOLETE #include "vx-share/xdr_rdb.h"
54 // OBSOLETE #include "vx-share/dbgRpcLib.h"
56 // OBSOLETE /* get rid of value.h if possible */
57 // OBSOLETE #include <value.h>
58 // OBSOLETE #include <symtab.h>
60 // OBSOLETE /* Flag set if target has fpu */
62 // OBSOLETE extern int target_has_fp;
64 // OBSOLETE /* 960 floating point format descriptor, from "i960-tdep.c." */
66 // OBSOLETE extern struct ext_format ext_format_i960;
68 // OBSOLETE /* Generic register read/write routines in remote-vx.c. */
70 // OBSOLETE extern void net_read_registers ();
71 // OBSOLETE extern void net_write_registers ();
73 // OBSOLETE /* Read a register or registers from the VxWorks target.
74 // OBSOLETE REGNO is the register to read, or -1 for all; currently,
75 // OBSOLETE it is ignored. FIXME look at regno to improve efficiency. */
78 // OBSOLETE vx_read_register (int regno)
80 // OBSOLETE char i960_greg_packet[I960_GREG_PLEN];
81 // OBSOLETE char i960_fpreg_packet[I960_FPREG_PLEN];
83 // OBSOLETE /* Get general-purpose registers. When copying values into
84 // OBSOLETE registers [], don't assume that a location in registers []
85 // OBSOLETE is properly aligned for the target data type. */
87 // OBSOLETE net_read_registers (i960_greg_packet, I960_GREG_PLEN, PTRACE_GETREGS);
89 // OBSOLETE bcopy (&i960_greg_packet[I960_R_R0],
90 // OBSOLETE ®isters[REGISTER_BYTE (R0_REGNUM)], 16 * I960_GREG_SIZE);
91 // OBSOLETE bcopy (&i960_greg_packet[I960_R_G0],
92 // OBSOLETE ®isters[REGISTER_BYTE (G0_REGNUM)], 16 * I960_GREG_SIZE);
93 // OBSOLETE bcopy (&i960_greg_packet[I960_R_PCW],
94 // OBSOLETE ®isters[REGISTER_BYTE (PCW_REGNUM)], sizeof (int));
95 // OBSOLETE bcopy (&i960_greg_packet[I960_R_ACW],
96 // OBSOLETE ®isters[REGISTER_BYTE (ACW_REGNUM)], sizeof (int));
97 // OBSOLETE bcopy (&i960_greg_packet[I960_R_TCW],
98 // OBSOLETE ®isters[REGISTER_BYTE (TCW_REGNUM)], sizeof (int));
100 // OBSOLETE /* If the target has floating point registers, fetch them.
101 // OBSOLETE Otherwise, zero the floating point register values in
102 // OBSOLETE registers[] for good measure, even though we might not
103 // OBSOLETE need to. */
105 // OBSOLETE if (target_has_fp)
107 // OBSOLETE net_read_registers (i960_fpreg_packet, I960_FPREG_PLEN,
108 // OBSOLETE PTRACE_GETFPREGS);
109 // OBSOLETE bcopy (&i960_fpreg_packet[I960_R_FP0],
110 // OBSOLETE ®isters[REGISTER_BYTE (FP0_REGNUM)],
111 // OBSOLETE REGISTER_RAW_SIZE (FP0_REGNUM) * 4);
114 // OBSOLETE bzero (®isters[REGISTER_BYTE (FP0_REGNUM)],
115 // OBSOLETE REGISTER_RAW_SIZE (FP0_REGNUM) * 4);
117 // OBSOLETE /* Mark the register cache valid. */
119 // OBSOLETE registers_fetched ();
122 // OBSOLETE /* Store a register or registers into the VxWorks target.
123 // OBSOLETE REGNO is the register to store, or -1 for all; currently,
124 // OBSOLETE it is ignored. FIXME look at regno to improve efficiency. */
127 // OBSOLETE vx_write_register (int regno)
129 // OBSOLETE char i960_greg_packet[I960_GREG_PLEN];
130 // OBSOLETE char i960_fpreg_packet[I960_FPREG_PLEN];
132 // OBSOLETE /* Store floating-point registers. When copying values from
133 // OBSOLETE registers [], don't assume that a location in registers []
134 // OBSOLETE is properly aligned for the target data type. */
136 // OBSOLETE bcopy (®isters[REGISTER_BYTE (R0_REGNUM)],
137 // OBSOLETE &i960_greg_packet[I960_R_R0], 16 * I960_GREG_SIZE);
138 // OBSOLETE bcopy (®isters[REGISTER_BYTE (G0_REGNUM)],
139 // OBSOLETE &i960_greg_packet[I960_R_G0], 16 * I960_GREG_SIZE);
140 // OBSOLETE bcopy (®isters[REGISTER_BYTE (PCW_REGNUM)],
141 // OBSOLETE &i960_greg_packet[I960_R_PCW], sizeof (int));
142 // OBSOLETE bcopy (®isters[REGISTER_BYTE (ACW_REGNUM)],
143 // OBSOLETE &i960_greg_packet[I960_R_ACW], sizeof (int));
144 // OBSOLETE bcopy (®isters[REGISTER_BYTE (TCW_REGNUM)],
145 // OBSOLETE &i960_greg_packet[I960_R_TCW], sizeof (int));
147 // OBSOLETE net_write_registers (i960_greg_packet, I960_GREG_PLEN, PTRACE_SETREGS);
149 // OBSOLETE /* Store floating point registers if the target has them. */
151 // OBSOLETE if (target_has_fp)
153 // OBSOLETE bcopy (®isters[REGISTER_BYTE (FP0_REGNUM)],
154 // OBSOLETE &i960_fpreg_packet[I960_R_FP0],
155 // OBSOLETE REGISTER_RAW_SIZE (FP0_REGNUM) * 4);
157 // OBSOLETE net_write_registers (i960_fpreg_packet, I960_FPREG_PLEN,
158 // OBSOLETE PTRACE_SETFPREGS);
This page took 0.032989 seconds and 4 git commands to generate.