Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Step over doesn't let me run one line at a time
Step over doesn't let me run one line at a time [message #1774702] Wed, 18 October 2017 18:38 Go to next message
Wanling  Jiang is currently offline Wanling JiangFriend
Messages: 1
Registered: October 2017
Junior Member
I run the C code in debug mode, and in one of the functions, I do step over, it starts to run, and it doesn't stop. I have simple assignments in the first few lines of the function.

However, initially, the step over runs, when it enter the function, the step over start to behave in this strange way.

Please help!
Thank you!
Re: Step over doesn't let me run one line at a time [message #1774938 is a reply to message #1774702] Sun, 22 October 2017 02:19 Go to previous message
David VavraFriend
Messages: 778
Registered: October 2012
Senior Member
A common reason for seemingly erratic debugging behavior is failure to turn off all optimization.
With GCC, you should compile with "-g -O0" (minus-capitalO-zero).

If optimization is already off, you may need to post a small example that illustrates what you are seeing.
It's not at all clear what you are describing.

What do you mean by: "starts to run, and it doesn't stop"?
Do you mean it runs to completion or otherwise terminates?
Perhaps the function is calling exit.
Perhaps it isn't returning to the point after the call (because of stack corruption, for example).

You may need to step into the function and single step to discover what it is doing.

[Updated on: Wed, 25 October 2017 03:21]

Report message to a moderator

Previous Topic:Errors upon importing an AVR project
Next Topic:external library update always requires re-indexing
Goto Forum:

Current Time: Mon Sep 24 21:39:35 GMT 2018

Powered by FUDForum. Page generated in 0.02307 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top