From bd1ef5d285d6883228c1d3910c05c1c37eccccb6 Mon Sep 17 00:00:00 2001 From: Andrew Cagney Date: Sun, 18 Nov 2001 22:14:13 +0000 Subject: [PATCH] * i386-tdep.c (i386_gdbarch_init): Initialize num_regs. * config/i386/tm-i386.h (NUM_REGS): Delete. --- gdb/ChangeLog | 5 +++++ gdb/config/i386/tm-i386.h | 2 -- gdb/i386-tdep.c | 4 ++++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 04168d94bdb..727536304cb 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2001-11-18 Andrew Cagney + + * i386-tdep.c (i386_gdbarch_init): Initialize num_regs. + * config/i386/tm-i386.h (NUM_REGS): Delete. + 2001-11-18 Kevin Buettner * i386-linux-nat.c (fill_gregset): Fix botched regcache_collect() diff --git a/gdb/config/i386/tm-i386.h b/gdb/config/i386/tm-i386.h index 7661bd8d56d..8407057ba37 100644 --- a/gdb/config/i386/tm-i386.h +++ b/gdb/config/i386/tm-i386.h @@ -124,8 +124,6 @@ extern CORE_ADDR i386_saved_pc_after_call (struct frame_info *frame); #define NUM_SSE_REGS (0) #endif -#define NUM_REGS (NUM_GREGS + NUM_FREGS + NUM_SSE_REGS) - /* Largest number of registers we could have in any configuration. */ #define MAX_NUM_REGS (16 + 16 + 9) diff --git a/gdb/i386-tdep.c b/gdb/i386-tdep.c index d5cf8895e06..0908273c76e 100644 --- a/gdb/i386-tdep.c +++ b/gdb/i386-tdep.c @@ -1229,6 +1229,10 @@ i386_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches) /* NOTE: tm-i386nw.h and tm-i386v4.h override this. */ set_gdbarch_frame_chain_valid (gdbarch, file_frame_chain_valid); + /* NOTE: tm-i386aix.h, tm-i386bsd.h, tm-i386os9k.h, tm-linux.h, + tm-ptx.h, tm-symmetry.h currently override this. Sigh. */ + set_gdbarch_num_regs (gdbarch, NUM_GREGS + NUM_FREGS + NUM_SSE_REGS); + return gdbarch; } -- 2.30.2