aboutsummaryrefslogtreecommitdiff
path: root/gdb/gdbarch.c
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2000-05-10 17:38:16 +0000
committerMichael Snyder <msnyder@vmware.com>2000-05-10 17:38:16 +0000
commit60054393321258d1acc88f65169fb60589cb4b41 (patch)
tree2e14d4aa8da30649e52937f14b5da33bcc4f42e5 /gdb/gdbarch.c
parent598ca718d00001789f64d2669c56f87acea2b3ca (diff)
downloadgdb-60054393321258d1acc88f65169fb60589cb4b41.zip
gdb-60054393321258d1acc88f65169fb60589cb4b41.tar.gz
gdb-60054393321258d1acc88f65169fb60589cb4b41.tar.bz2
2000-05-08 Michael Snyder <msnyder@seadog.cygnus.com>
* gdbarch.sh: Add FP0_REGNUM to list of multi-arched register numbers. * gdbarch.c, gdbarch.h: Regenerate. * core-regset.c: Change FP0_REGNUM to a runtime test. * procfs.c: Ditto. * sun3-nat.c: Ditto. * sparc-tdep.c: Ditto. * i386mach-nat.c: Remove unnecessary ifdef for FP0_REGNUM. * ptx4-nat.c: Ditto. * sol-thread.c (sol_thread_create_inferior): only add the thread to the thread list if it is not already in there. (prototypes for thread_db func ptrs): pretty up formatting.
Diffstat (limited to 'gdb/gdbarch.c')
-rw-r--r--gdb/gdbarch.c23
1 files changed, 23 insertions, 0 deletions
diff --git a/gdb/gdbarch.c b/gdb/gdbarch.c
index 17bed5c..4cfb8bc 100644
--- a/gdb/gdbarch.c
+++ b/gdb/gdbarch.c
@@ -146,6 +146,7 @@ struct gdbarch
int sp_regnum;
int fp_regnum;
int pc_regnum;
+ int fp0_regnum;
int npc_regnum;
int nnpc_regnum;
gdbarch_register_name_ftype *register_name;
@@ -283,6 +284,7 @@ struct gdbarch startup_gdbarch = {
0,
0,
0,
+ 0,
generic_get_saved_register,
0,
0,
@@ -353,6 +355,7 @@ gdbarch_alloc (const struct gdbarch_info *info,
gdbarch->sp_regnum = -1;
gdbarch->fp_regnum = -1;
gdbarch->pc_regnum = -1;
+ gdbarch->fp0_regnum = -1;
gdbarch->npc_regnum = -1;
gdbarch->nnpc_regnum = -1;
gdbarch->register_name = legacy_register_name;
@@ -472,6 +475,7 @@ verify_gdbarch (struct gdbarch *gdbarch)
if ((GDB_MULTI_ARCH >= 2)
&& (gdbarch->pc_regnum == -1))
internal_error ("gdbarch: verify_gdbarch: pc_regnum invalid");
+ /* Skip verify of fp0_regnum, invalid_p == 0 */
/* Skip verify of npc_regnum, invalid_p == 0 */
/* Skip verify of nnpc_regnum, invalid_p == 0 */
/* Skip verify of register_name, invalid_p == 0 */
@@ -712,6 +716,9 @@ gdbarch_dump (void)
"gdbarch_update: PC_REGNUM = %ld\n",
(long) PC_REGNUM);
fprintf_unfiltered (gdb_stdlog,
+ "gdbarch_update: FP0_REGNUM = %ld\n",
+ (long) FP0_REGNUM);
+ fprintf_unfiltered (gdb_stdlog,
"gdbarch_update: NPC_REGNUM = %ld\n",
(long) NPC_REGNUM);
fprintf_unfiltered (gdb_stdlog,
@@ -1349,6 +1356,22 @@ set_gdbarch_pc_regnum (struct gdbarch *gdbarch,
}
int
+gdbarch_fp0_regnum (struct gdbarch *gdbarch)
+{
+ /* Skip verify of fp0_regnum, invalid_p == 0 */
+ if (gdbarch_debug >= 2)
+ fprintf_unfiltered (gdb_stdlog, "gdbarch_fp0_regnum called\n");
+ return gdbarch->fp0_regnum;
+}
+
+void
+set_gdbarch_fp0_regnum (struct gdbarch *gdbarch,
+ int fp0_regnum)
+{
+ gdbarch->fp0_regnum = fp0_regnum;
+}
+
+int
gdbarch_npc_regnum (struct gdbarch *gdbarch)
{
/* Skip verify of npc_regnum, invalid_p == 0 */