Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » gdb debug stepping behavios unexpectvily
gdb debug stepping behavios unexpectvily [message #902323] Fri, 17 August 2012 01:05 Go to next message
anil kumar is currently offline anil kumar
Messages: 17
Registered: January 2012
Junior Member
i am new to C and C++, i have created a simple Helloworld.cpp project using managed make by selecting cygwin as toolchain,and build the project ,exe got generated successfully, then i am running the exe as Debug as->local c/c++ Application,the application opened in debug mode and Helloworld.cpp opended and break point first statement of main method,then i have started clicking on step in function,after some clicks gdb hang's ,i am not able to do any thing.
only Terminal button is enabled ,i have attached the screen shots also please have a look, if i give "info thread" command in gdb console getting following trace.
info thread
Id Target Id Frame
2 Thread 5800.0x1690 0x7c90e514 in ntdll!LdrAccessResource () from /cygdrive/c/WINDOWS/system32/ntdll.dll
* 1 Thread 5800.0x1a20 0x610b5d00 in dirname () from /cygdrive/c/cygwin/bin/cygwin1.dll

even i am not able to see the helloworld.cpp output.

what is the problem and how to resolve it.
Re: gdb debug stepping behavios unexpectvily [message #902414 is a reply to message #902323] Fri, 17 August 2012 10:04 Go to previous messageGo to next message
Nick Schweyer is currently offline Nick Schweyer
Messages: 151
Registered: July 2009
Senior Member
hi,

when the program has run to the line with "cout << ..." and you step one line ahead then the output should be visible. But if the Eclipse window is in front of the programs output window you will not see it automatically. You have to click on the programs output window to put it on top of all windows. Then - hopefully - you will see it.

I am using Eclipse with Linux, but the behaviour of gdb should be the same as in Windows.



Nick Schweyer

Eclipse Helios, Qt 4.3, Qt integration, open Suse Linux 11.3
Re: gdb debug stepping behavios unexpectvily [message #902459 is a reply to message #902414] Fri, 17 August 2012 13:18 Go to previous message
anil kumar is currently offline anil kumar
Messages: 17
Registered: January 2012
Junior Member
you means to say , while "cout<< " statement we didn't apply step in function? and i am keeping program window top even,i am not able to see any output,simply it hangs.

Previous Topic:Simulation randomly stop
Next Topic:how to implement custom build in CDT
Goto Forum:
  


Current Time: Tue Jul 29 23:13:23 EDT 2014

Powered by FUDForum. Page generated in 0.03357 seconds