aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorMaxim Kuvyrkov <maxim@kugelworks.com>2009-11-17 17:56:11 +0000
committerMaxim Kuvyrkov <maxim@kugelworks.com>2009-11-17 17:56:11 +0000
commit86443c3e9445d0cce7138f913c8979972c1d7b9d (patch)
tree7431bb8f9626a5481fc9d863ae5ead633decba21 /gdb
parentaefd8a406ce2c3fb7917a232357181d9629b4323 (diff)
downloadgdb-86443c3e9445d0cce7138f913c8979972c1d7b9d.zip
gdb-86443c3e9445d0cce7138f913c8979972c1d7b9d.tar.gz
gdb-86443c3e9445d0cce7138f913c8979972c1d7b9d.tar.bz2
2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
* m68k-tdep.c (m68k_register_name): Check fpregs_present. (m68k_gdbarch_init): Remove a duplicate of set_gdbarch_fp0_regnum.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/m68k-tdep.c4
2 files changed, 8 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 9ff2447..049152c 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * m68k-tdep.c (m68k_register_name): Check fpregs_present.
+ (m68k_gdbarch_init): Remove a duplicate of set_gdbarch_fp0_regnum.
+
2009-11-17 Jan Kratochvil <jan.kratochvil@redhat.com>
Fix wrong debug output with `set debug infrun 1'.
diff --git a/gdb/m68k-tdep.c b/gdb/m68k-tdep.c
index dcf8779..9cbbbb3 100644
--- a/gdb/m68k-tdep.c
+++ b/gdb/m68k-tdep.c
@@ -179,6 +179,9 @@ m68k_register_name (struct gdbarch *gdbarch, int regnum)
if (regnum < 0 || regnum >= ARRAY_SIZE (m68k_register_names))
internal_error (__FILE__, __LINE__,
_("m68k_register_name: illegal register number %d"), regnum);
+ else if (regnum >= M68K_FP0_REGNUM && regnum <= M68K_FPI_REGNUM
+ && gdbarch_tdep (gdbarch)->fpregs_present == 0)
+ return "";
else
return m68k_register_names[regnum];
}
@@ -1190,7 +1193,6 @@ m68k_gdbarch_init (struct gdbarch_info info, struct gdbarch_list *arches)
set_gdbarch_sp_regnum (gdbarch, M68K_SP_REGNUM);
set_gdbarch_pc_regnum (gdbarch, M68K_PC_REGNUM);
set_gdbarch_ps_regnum (gdbarch, M68K_PS_REGNUM);
- set_gdbarch_fp0_regnum (gdbarch, M68K_FP0_REGNUM);
set_gdbarch_convert_register_p (gdbarch, m68k_convert_register_p);
set_gdbarch_register_to_value (gdbarch, m68k_register_to_value);
set_gdbarch_value_to_register (gdbarch, m68k_value_to_register);