diff options
Diffstat (limited to 'gdb/gdbarch.h')
-rw-r--r-- | gdb/gdbarch.h | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/gdb/gdbarch.h b/gdb/gdbarch.h index d3b6170..b90a553 100644 --- a/gdb/gdbarch.h +++ b/gdb/gdbarch.h @@ -1,7 +1,7 @@ /* *INDENT-OFF* */ /* THIS FILE IS GENERATED */ /* Dynamic architecture support for GDB, the GNU debugger. - Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc. + Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. This file is part of GDB. @@ -2040,6 +2040,26 @@ extern void set_gdbarch_addr_bits_remove (struct gdbarch *gdbarch, gdbarch_addr_ #endif #endif +/* It is not at all clear why SMASH_TEXT_ADDRESS is not folded into + ADDR_BITS_REMOVE. */ + +/* Default (function) for non- multi-arch platforms. */ +#if (!GDB_MULTI_ARCH) && !defined (SMASH_TEXT_ADDRESS) +#define SMASH_TEXT_ADDRESS(addr) (core_addr_identity (addr)) +#endif + +typedef CORE_ADDR (gdbarch_smash_text_address_ftype) (CORE_ADDR addr); +extern CORE_ADDR gdbarch_smash_text_address (struct gdbarch *gdbarch, CORE_ADDR addr); +extern void set_gdbarch_smash_text_address (struct gdbarch *gdbarch, gdbarch_smash_text_address_ftype *smash_text_address); +#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) && defined (SMASH_TEXT_ADDRESS) +#error "Non multi-arch definition of SMASH_TEXT_ADDRESS" +#endif +#if GDB_MULTI_ARCH +#if (GDB_MULTI_ARCH > GDB_MULTI_ARCH_PARTIAL) || !defined (SMASH_TEXT_ADDRESS) +#define SMASH_TEXT_ADDRESS(addr) (gdbarch_smash_text_address (current_gdbarch, addr)) +#endif +#endif + /* FIXME/cagney/2001-01-18: This should be split in two. A target method that indicates if the target needs software single step. An ISA method to implement it. |