2000-05-26 Michael Snyder <msnyder@seadog.cygnus.com>
[external/binutils.git] / gdb / gregset.h
1 /* Interface for functions using gregset and fpregset types.
2    Copyright (C) 2000 Free Software Foundation, Inc.
3
4    This file is part of GDB.
5
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.
10
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.
15
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.  */
20
21 #ifndef GDB_GREGSET_T
22 #define GDB_GREGSET_T gregset_t
23 #endif
24
25 #ifndef GDB_FPREGSET_T
26 #define GDB_FPREGSET_T fpregset_t
27 #endif
28
29 typedef GDB_GREGSET_T  gdb_gregset_t;
30 typedef GDB_FPREGSET_T gdb_fpregset_t;
31
32 /* A gregset is a data structure supplied by the native OS containing
33    the general register values of the debugged process.  Usually this
34    includes integer registers and control registers.  An fpregset is a
35    data structure containing the floating point registers.  These data
36    structures were originally a part of the /proc interface, but have
37    been borrowed or copied by other GDB targets, eg. Linux.  */
38
39 /* Copy register values from the native target gregset / fpregset
40    into GDB's internal register cache.  */
41
42 extern void supply_gregset  (gdb_gregset_t *gregs);
43 extern void supply_fpregset (gdb_fpregset_t *fpregs);
44
45 /* Copy register values from GDB's register cache into
46    the native target gregset / fpregset.  If regno is -1, 
47    copy all the registers.  */
48
49 extern void fill_gregset    (gdb_gregset_t *gregs, int regno);
50 extern void fill_fpregset   (gdb_fpregset_t *fpregs, int regno);