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