Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 333223 - Eclipse GDB Hardware Debugging: 'hook-continue' ignored
Summary: Eclipse GDB Hardware Debugging: 'hook-continue' ignored
Status: RESOLVED WONTFIX
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug-cdi-gdb (show other bugs)
Version: 8.0   Edit
Hardware: PC Linux
: P3 major with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact: Elena Laskavaia CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-26 15:45 EST by Frikkie Thirion CLA
Modified: 2017-10-23 13:43 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frikkie Thirion CLA 2010-12-26 15:45:29 EST
Build Identifier: 20100917-0705

(Test preformed with CDT_master I201009241320 and I201010271448)

In order to disable and enable the interrupts on the ARM Cortex-M3 while debugging, specific commands can be send to the OpenOCD JTAG interface, namely:
"cortex_m3 maskisr off" and "cortex_m3 maskisr on"

To accomplish this, GDB needs to send these commands to OpenOCD when program execution is halted (Ctrl-C), single stepped (step and next) and resumed (continue)

The following GDB command file accomplishes this
# -- Start --
define hook-continue
mon cortex_m3 maskisr off
end

define hook-stop
mon cortex_m3 maskisr on
end

define hook-step
mon cortex_m3 maskisr on
end

define hook-next
mon cortex_m3 maskisr on
end
# -- End --

When using this command file with a GDB debug session directly in the text user interface (gdbtui), all the hooks are exercised.

When launching the debug session via the GDB Hardware Debugging Plug-in, all the hooks are exercised, except for 'hook-continue' (Resume)

-->Is there a reason why Eclipse won't allow 'hook-continue' to be registered in GDB?

The program debugging can't be accomplished without interrupts being reenabled upon resuming of the program, making this a major problem

Reproducible: Always

Steps to Reproduce:
1.Create a debug command file 'gdbCommands', containing the hook-XXXs defined above.
2.In the Debug configurations, create a GDB Hardware Debugging configuration, specifying the GDB command in the Debugger tab: <path to gdb>/arm-none-eabi-gdb --command=gdbCommands
3.Launch the debug session
(Note: An ARM development kit, hardware JTAG and OpenOCD will probably be required to reproduce the bug)
Comment 1 Jonah Graham CLA 2017-10-23 13:43:38 EDT
(this is part of a batch change)

The CDI debug implementation has been removed in CDT 9.0. Please see bug 484900 and the entry on the New and Noteworthy page https://wiki.eclipse.org/CDT/User/NewIn90#API_modifications