aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/arm-tdep.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index f32d1f7..8d90992 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2014-05-16 Taimoor Mirza <tmirza@codesourcery.com>
+
+ * arm-tdep.c (thumb_analyze_prologue): Fix offset calculation for
+ ldr.w and ldrd instructions.
+
2014-05-15 Doug Evans <dje@google.com>
* dwarf2read.c (read_structure_type): Delete outdated comments.
diff --git a/gdb/arm-tdep.c b/gdb/arm-tdep.c
index e3b1c3d..7271777 100644
--- a/gdb/arm-tdep.c
+++ b/gdb/arm-tdep.c
@@ -1071,7 +1071,7 @@ thumb_analyze_prologue (struct gdbarch *gdbarch,
unsigned int constant;
CORE_ADDR loc;
- offset = bits (insn, 0, 11);
+ offset = bits (inst2, 0, 11);
if (insn & 0x0080)
loc = start + 4 + offset;
else
@@ -1087,7 +1087,7 @@ thumb_analyze_prologue (struct gdbarch *gdbarch,
unsigned int constant;
CORE_ADDR loc;
- offset = bits (insn, 0, 7) << 2;
+ offset = bits (inst2, 0, 7) << 2;
if (insn & 0x0080)
loc = start + 4 + offset;
else