Debugging with minGW GDB [message #524825] |
Fri, 02 April 2010 15:00  |
Eclipse User |
|
|
|
Eclipse Galileo, all components are the latest from the download sites.
I have a medium sized multi-threaded application that I can stop and start (suspend and resume) successfully when I use minGW GDB from the command window. However, I am not able to do the same when I use CDT.
When I suspend the program, it takes several seconds to show it as suspended and my threads disappear from the Debug view. When I try to resume, I get a popup stating that "Target request failed: Target is not responding (timed out)."
I've tried using both GDB 6.6 and GDB 7.0 from the minGW download site. The Debug Configuration is setup to use MinGW gdb Debugger, Standard (Windows), and Protocol mi.
Here is the information I see in the Console window when this happens:
Num Active Threads = 0
Final Num Active Threads = 0~"[Switching to thread 3104.0x113c]\n"
250*stopped,reason="signal-received",signal-name="SIGINT",signal-meaning= "Interrupt",thread-id="4",frame={addr="0x7c87647d",func= "KERNEL32!GetConsoleCharType",args=[],from="C:\\WINDOWS\\system32\\kernel32.dll "}
(gdb)
&"Quit (expect signal SIGINT when the program is resumed)\n"
251 info threads
252 info threads
253 info signal SIGINT
254 info threads
255-exec-continue
Does anyone have any ideas?
[Updated on: Fri, 02 April 2010 15:11] by Moderator
|
|
|
Re: Debugging with minGW GDB [message #524846 is a reply to message #524825] |
Fri, 02 April 2010 18:40   |
Eclipse User |
|
|
|
Additional information.
If I step through the code that appears to be the problem (a thread sleep command Sleep(msecs*(CLOCKS_PER_SEC/1000)) GDB reports this:
*stopped,reason="end-stepping-range",frame={addr="0x004110ec ",func="main",args=[{name="argc",value="1"},{name="argv ",value="0x3e4ce8"}],file="<omitted, relative path to file>",fullname="<omitted, full path to file>",line="493"},thread-id="1",stopped-threads="all"
This happens after I step over the sleep command, which should actually allow all of my other threads to run. It does work at the command line.
|
|
|
|
Re: Debugging with minGW GDB [message #525249 is a reply to message #525066] |
Mon, 05 April 2010 16:12  |
Eclipse User |
|
|
|
Thanks for the reply. I did try the DSF configuration (guess I should have mentioned that before) but it exhibited the same behavior.
An interesting data point that I forgot to mention before. Before I downloaded the latest packages, I had the Debugger type set to gdb/mi and it exhibited the behavior described in my previous posts. But, when I went back and changed the Debugger type to MinGW GDB, the GUI for the configuration window stopped working properly (could not set any of the fields and kept getting a null pointer error) but the debugger started working correctly. After downloading the updated packages, it went back to behaving like I described in my previous posts.
Is there any specific information that I could post that might help?
Thanks Again
|
|
|
Powered by
FUDForum. Page generated in 0.27891 seconds