summaryrefslogtreecommitdiff
path: root/gdb/gdbarch.h
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2002-08-10 02:00:16 +0000
committerAndrew Cagney <cagney@redhat.com>2002-08-10 02:00:16 +0000
commit728d8c4e7a4813b6940fb097220710be4d6bde3b (patch)
treec096cf48edfadffa09dbd1df9cd9d795cae1db39 /gdb/gdbarch.h
parent59c813c0c84a2b77d3c60ee8e697b5a9df3a8fa6 (diff)
downloadgdb-728d8c4e7a4813b6940fb097220710be4d6bde3b.tar.gz
2002-08-09 Andrew Cagney <cagney@redhat.com>
* regcache.c (regcache_dump): Compare the register offset with REGISTER_BYTE. * arch-utils.c (generic_register_byte): New function. * arch-utils.h (generic_register_byte): Declare. * gdbarch.sh (REGISTER_BYTE): Default to generic_register_byte. * gdbarch.h, gdbarch.c: Regenerate.
Diffstat (limited to 'gdb/gdbarch.h')
-rw-r--r--gdb/gdbarch.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h
index 57fb0cf71f5..973f250b626 100644
--- a/gdb/gdbarch.h
+++ b/gdb/gdbarch.h
@@ -693,6 +693,11 @@ extern void set_gdbarch_register_bytes (struct gdbarch *gdbarch, int register_by
#endif
#endif
+/* Default (function) for non- multi-arch platforms. */
+#if (!GDB_MULTI_ARCH) && !defined (REGISTER_BYTE)
+#define REGISTER_BYTE(reg_nr) (generic_register_byte (reg_nr))
+#endif
+
typedef int (gdbarch_register_byte_ftype) (int reg_nr);
extern int gdbarch_register_byte (struct gdbarch *gdbarch, int reg_nr);
extern void set_gdbarch_register_byte (struct gdbarch *gdbarch, gdbarch_register_byte_ftype *register_byte);