X-Git-Url: https://repo.jachan.dev/binutils.git/blobdiff_plain/3c0c9328b9c299580bcf8cb6fdb3b71d5a0525ff..58050209857ca9ef632254dd05cae407cf7f7a0d:/gdb/sparc-xdep.c diff --git a/gdb/sparc-xdep.c b/gdb/sparc-xdep.c index 89fcb8d0a9..b09dbe888a 100644 --- a/gdb/sparc-xdep.c +++ b/gdb/sparc-xdep.c @@ -5,19 +5,19 @@ This file is part of GDB. -GDB is free software; you can redistribute it and/or modify +This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 1, or (at your option) -any later version. +the Free Software Foundation; either version 2 of the License, or +(at your option) any later version. -GDB is distributed in the hope that it will be useful, +This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License -along with GDB; see the file COPYING. If not, write to -the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ +along with this program; if not, write to the Free Software +Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ #include #include "defs.h" @@ -37,6 +37,18 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ extern char register_valid[]; +/* We don't store all registers immediately when requested, since they + get sent over in large chunks anyway. Instead, we accumulate most + of the changes and send them over once. "deferred_stores" keeps + track of which sets of registers we have locally-changed copies of, + so we only need send the groups that have changed. */ + +#define INT_REGS 1 +#define STACK_REGS 2 +#define FP_REGS 4 + +int deferred_stores = 0; /* Cumulates stores we want to do eventually. */ + /* Fetch one or more registers from the inferior. REGNO == -1 to get them all. We actually fetch more than requested, when convenient, marking them as valid so we won't fetch them again. */ @@ -128,11 +140,6 @@ fetch_inferior_registers (regno) If REGNO is -1, do this for all registers. Otherwise, REGNO specifies which register (so we can save time). */ -#define INT_REGS 1 -#define STACK_REGS 2 -#define FP_REGS 4 -int deferred_stores = 0; /* Cumulates stores we want to do eventually. */ - int store_inferior_registers (regno) int regno;