aboutsummaryrefslogtreecommitdiff
path: root/gdb/arm-tdep.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/arm-tdep.c')
-rw-r--r--gdb/arm-tdep.c9
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)
{