This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug breakpoints/16263] New: breakpoints on BL instruction in Thumb broken
- From: "js at sig21 dot net" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Wed, 27 Nov 2013 12:47:40 +0000
- Subject: [Bug breakpoints/16263] New: breakpoints on BL instruction in Thumb broken
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=16263
Bug ID: 16263
Summary: breakpoints on BL instruction in Thumb broken
Product: gdb
Version: unknown
Status: NEW
Severity: normal
Priority: P2
Component: breakpoints
Assignee: unassigned at sourceware dot org
Reporter: js at sig21 dot net
For the ARM target, commit 177321bd85d5a3d4ca05d320696d8af43bc0fc05
(Daniel Jacobowitz, Mon Feb 1 16:13:17 2010), which added Thumb2
breakpoint support, broke breakpoints set on the BL instruction in
Thumb mode (and thus single stepping through Thumb code).
arm_breakpoint_from_pc() inserts tdep->thumb2_breakpoint
instead of tdep->thumb_breakpoint because the length of the BL
instruction is 32bit (two 16bit instructions).
The code has this:
+ /* If we have a separate 32-bit breakpoint instruction for Thumb-2,
+ check whether we are replacing a 32-bit instruction. */
+ if (tdep->thumb2_breakpoint != NULL)
but tdep->thumb2_breakpoint is set unconditionally in arm_linux_init_abi().
I confirmed that commenting out
// tdep->thumb2_breakpoint = arm_linux_thumb2_le_breakpoint;
works around the issue.
It seems the assignment should be made
depending on whether the target actually has Thumb2 support.
--
You are receiving this mail because:
You are on the CC list for the bug.