diff options
author | Ulrich Weigand <uweigand@de.ibm.com> | 2007-10-30 21:54:06 +0000 |
---|---|---|
committer | Ulrich Weigand <uweigand@de.ibm.com> | 2007-10-30 21:54:06 +0000 |
commit | 7067c689774e8337600d73759f4d6f1861bb7b83 (patch) | |
tree | 6b2cbe4be4e39def4bed4fb1d9fc72178dcd0e94 | |
parent | 8a7e34d89e12307fdf6f8c919bf05b4a8ffb1572 (diff) | |
download | gdb-7067c689774e8337600d73759f4d6f1861bb7b83.zip gdb-7067c689774e8337600d73759f4d6f1861bb7b83.tar.gz gdb-7067c689774e8337600d73759f4d6f1861bb7b83.tar.bz2 |
2007-10-30 Markus Deuling <deuling@de.ibm.com>
* go32-nat.c (fetch_register, go32_fetch_registers, store_register)
(go32_store_registers): Use get_regcache_arch to get at the current
architecture by regcache.
-rw-r--r-- | gdb/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/go32-nat.c | 10 |
2 files changed, 12 insertions, 4 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 1f2c4e0..14ead8b 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,11 @@ 2007-10-30 Markus Deuling <deuling@de.ibm.com> + * go32-nat.c (fetch_register, go32_fetch_registers, store_register) + (go32_store_registers): Use get_regcache_arch to get at the current + architecture by regcache. + +2007-10-30 Markus Deuling <deuling@de.ibm.com> + * gdbtypes.c (gdbtypes_post_init): Replace current_gdbarch by gdbarch. 2007-10-30 Markus Deuling <deuling@de.ibm.com> diff --git a/gdb/go32-nat.c b/gdb/go32-nat.c index 6196ed7..095ff66 100644 --- a/gdb/go32-nat.c +++ b/gdb/go32-nat.c @@ -465,7 +465,7 @@ go32_wait (ptid_t ptid, struct target_waitstatus *status) static void fetch_register (struct regcache *regcache, int regno) { - if (regno < gdbarch_fp0_regnum (current_gdbarch)) + if (regno < gdbarch_fp0_regnum (get_regcache_arch (regcache))) regcache_raw_supply (regcache, regno, (char *) &a_tss + regno_mapping[regno].tss_ofs); else if (i386_fp_regnum_p (regno) || i386_fpc_regnum_p (regno)) @@ -482,7 +482,9 @@ go32_fetch_registers (struct regcache *regcache, int regno) fetch_register (regcache, regno); else { - for (regno = 0; regno < gdbarch_fp0_regnum (current_gdbarch); regno++) + for (regno = 0; + regno < gdbarch_fp0_regnum (get_regcache_arch (regcache)); + regno++) fetch_register (regcache, regno); i387_supply_fsave (regcache, -1, &npx); } @@ -491,7 +493,7 @@ go32_fetch_registers (struct regcache *regcache, int regno) static void store_register (const struct regcache *regcache, int regno) { - if (regno < gdbarch_fp0_regnum (current_gdbarch)) + if (regno < gdbarch_fp0_regnum (get_regcache_arch (regcache))) regcache_raw_collect (regcache, regno, (char *) &a_tss + regno_mapping[regno].tss_ofs); else if (i386_fp_regnum_p (regno) || i386_fpc_regnum_p (regno)) @@ -510,7 +512,7 @@ go32_store_registers (struct regcache *regcache, int regno) store_register (regcache, regno); else { - for (r = 0; r < gdbarch_fp0_regnum (current_gdbarch); r++) + for (r = 0; r < gdbarch_fp0_regnum (get_regcache_arch (regcache)); r++) store_register (regcache, r); i387_collect_fsave (regcache, -1, &npx); } |