From 65e78234430ffd4a8671d30ff0c5f1af55e3f312 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Sat, 15 Jun 2002 17:04:04 +0000 Subject: [PATCH] * i386gnu-nat.c (supply_gregset, gnu_fetch_registers, gnu_store_registers): Replace usage of NUM_GREGS with I386_NUM_GREGS. --- gdb/ChangeLog | 4 ++++ gdb/i386gnu-nat.c | 16 ++++++++-------- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index dd383f9b54..a1b2bace08 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,9 @@ 2002-06-15 Mark Kettenis + * i386gnu-nat.c (supply_gregset, gnu_fetch_registers, + gnu_store_registers): Replace usage of NUM_GREGS with + I386_NUM_GREGS. + * i386-linux-nat.c (OLD_CANNOT_FETCH_REGISTER, OLD_CANNOT_STORE_REGISTER, supply_gregset, fill_gregset): Replace usage of NUM_GREGS with I386_NUM_GREGS. diff --git a/gdb/i386gnu-nat.c b/gdb/i386gnu-nat.c index 329ef2fd17..3fa99a34d8 100644 --- a/gdb/i386gnu-nat.c +++ b/gdb/i386gnu-nat.c @@ -99,7 +99,7 @@ void supply_gregset (gdb_gregset_t *gregs) { int i; - for (i = 0; i < NUM_GREGS; i++) + for (i = 0; i < I386_NUM_GREGS; i++) supply_register (i, REG_ADDR (gregs, i)); } @@ -124,7 +124,7 @@ gnu_fetch_registers (int regno) error ("Can't fetch registers from thread %d: No such thread", PIDGET (inferior_ptid)); - if (regno < NUM_GREGS || regno == -1) + if (regno < I386_NUM_GREGS || regno == -1) { thread_state_t state; @@ -143,7 +143,7 @@ gnu_fetch_registers (int regno) proc_debug (thread, "fetching all register"); - for (i = 0; i < NUM_GREGS; i++) + for (i = 0; i < I386_NUM_GREGS; i++) supply_register (i, REG_ADDR (state, i)); thread->fetched_regs = ~0; } @@ -156,7 +156,7 @@ gnu_fetch_registers (int regno) } } - if (regno >= NUM_GREGS || regno == -1) + if (regno >= I386_NUM_GREGS || regno == -1) { proc_debug (thread, "fetching floating-point registers"); @@ -211,7 +211,7 @@ gnu_store_registers (int regno) error ("Couldn't store registers into thread %d: No such thread", PIDGET (inferior_ptid)); - if (regno < NUM_GREGS || regno == -1) + if (regno < I386_NUM_GREGS || regno == -1) { thread_state_t state; thread_state_data_t old_state; @@ -238,7 +238,7 @@ gnu_store_registers (int regno) { int check_regno; - for (check_regno = 0; check_regno < NUM_GREGS; check_regno++) + for (check_regno = 0; check_regno < I386_NUM_GREGS; check_regno++) if ((thread->fetched_regs & (1 << check_regno)) && memcpy (REG_ADDR (&old_state, check_regno), REG_ADDR (state, check_regno), @@ -265,7 +265,7 @@ gnu_store_registers (int regno) proc_debug (thread, "storing all registers"); - for (i = 0; i < NUM_GREGS; i++) + for (i = 0; i < I386_NUM_GREGS; i++) if (register_valid[i]) fill (state, i); } @@ -284,7 +284,7 @@ gnu_store_registers (int regno) #undef fill - if (regno >= NUM_GREGS || regno == -1) + if (regno >= I386_NUM_GREGS || regno == -1) { proc_debug (thread, "storing floating-point registers");