1*b725ae77Skettenis /* Register protocol definition structures for the GNU Debugger 2*b725ae77Skettenis Copyright 2001, 2002 Free Software Foundation, Inc. 3*b725ae77Skettenis 4*b725ae77Skettenis This file is part of GDB. 5*b725ae77Skettenis 6*b725ae77Skettenis This program is free software; you can redistribute it and/or modify 7*b725ae77Skettenis it under the terms of the GNU General Public License as published by 8*b725ae77Skettenis the Free Software Foundation; either version 2 of the License, or 9*b725ae77Skettenis (at your option) any later version. 10*b725ae77Skettenis 11*b725ae77Skettenis This program is distributed in the hope that it will be useful, 12*b725ae77Skettenis but WITHOUT ANY WARRANTY; without even the implied warranty of 13*b725ae77Skettenis MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14*b725ae77Skettenis GNU General Public License for more details. 15*b725ae77Skettenis 16*b725ae77Skettenis You should have received a copy of the GNU General Public License 17*b725ae77Skettenis along with this program; if not, write to the Free Software 18*b725ae77Skettenis Foundation, Inc., 59 Temple Place - Suite 330, 19*b725ae77Skettenis Boston, MA 02111-1307, USA. */ 20*b725ae77Skettenis 21*b725ae77Skettenis #ifndef REGDEF_H 22*b725ae77Skettenis #define REGDEF_H 23*b725ae77Skettenis 24*b725ae77Skettenis struct reg 25*b725ae77Skettenis { 26*b725ae77Skettenis /* The name of this register - NULL for pad entries. */ 27*b725ae77Skettenis const char *name; 28*b725ae77Skettenis 29*b725ae77Skettenis /* At the moment, both of the following bit counts must be divisible 30*b725ae77Skettenis by eight (to match the representation as two hex digits) and divisible 31*b725ae77Skettenis by the size of a byte (to match the layout of each register in 32*b725ae77Skettenis memory). */ 33*b725ae77Skettenis 34*b725ae77Skettenis /* The offset (in bits) of the value of this register in the buffer. */ 35*b725ae77Skettenis int offset; 36*b725ae77Skettenis 37*b725ae77Skettenis /* The size (in bits) of the value of this register, as transmitted. */ 38*b725ae77Skettenis int size; 39*b725ae77Skettenis }; 40*b725ae77Skettenis 41*b725ae77Skettenis /* Set the current remote protocol and register cache according to the array 42*b725ae77Skettenis ``regs'', with ``n'' elements. */ 43*b725ae77Skettenis 44*b725ae77Skettenis void set_register_cache (struct reg *regs, int n); 45*b725ae77Skettenis 46*b725ae77Skettenis #endif /* REGDEF_H */ 47