diff options
author | Richard Earnshaw <richard.earnshaw@arm.com> | 2002-02-04 11:55:36 +0000 |
---|---|---|
committer | Richard Earnshaw <richard.earnshaw@arm.com> | 2002-02-04 11:55:36 +0000 |
commit | 181c1381a54475957d907a7d86948548e17b9c0f (patch) | |
tree | 72c065b37c11ca2d77853a62857bda0ff499ddaf /gdb/arm-tdep.c | |
parent | fa4ba8da6c28c972dd1b6b9971e29b51aabaafcc (diff) | |
download | gdb-181c1381a54475957d907a7d86948548e17b9c0f.zip gdb-181c1381a54475957d907a7d86948548e17b9c0f.tar.gz gdb-181c1381a54475957d907a7d86948548e17b9c0f.tar.bz2 |
* gdbarch.sh (copyright): Update years in generated header.
(SMASH_TEXT_ADDRESS): Add rule.
*gdbarch.h, gdbarch.c: Re-generate.
* coffread.c: Multi-arch uses of SMASH_TEXT_ADDRESS.
* dbxread.c: Likewise.
* dwarfread.c: Likewise.
* elfread.c: Likewise.
* somread.c: Likewise.
* arm-tdep.c (arm_smash_text_address): New function.
* config/arm/tm-arm.h (SMASH_TEXT_ADDRESS): Define in terms of above.
Diffstat (limited to 'gdb/arm-tdep.c')
-rw-r--r-- | gdb/arm-tdep.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c index 1539d0d..f9ffa71 100644 --- a/gdb/arm-tdep.c +++ b/gdb/arm-tdep.c @@ -282,6 +282,7 @@ arm_pc_is_thumb_dummy (CORE_ADDR memaddr) return 0; } +/* Remove useless bits from addresses in a running program. */ CORE_ADDR arm_addr_bits_remove (CORE_ADDR val) { @@ -291,6 +292,14 @@ arm_addr_bits_remove (CORE_ADDR val) return (val & (arm_apcs_32 ? 0xfffffffc : 0x03fffffc)); } +/* When reading symbols, we need to zap the low bit of the address, + which may be set to 1 for Thumb functions. */ +CORE_ADDR +arm_smash_text_address (CORE_ADDR val) +{ + return val & ~1; +} + CORE_ADDR arm_saved_pc_after_call (struct frame_info *frame) { |