Author Topic: Issue with step-wise debugging (F7) in debugger branch  (Read 6008 times)

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Issue with step-wise debugging (F7) in debugger branch
« on: August 21, 2011, 03:30:54 pm »
I experience an issue with the current SVN head version of the debugger branch:

Stepwise debugging ("next line", F7) seems not to work for me anymore or at least works not reliable. Whenever I hit "F7" is sometimes steps to the next line in the code, but then suddenly somewhere completely different - sometimes it steps deeper into the code, sometimes it seems to step out.

Does anyone else experience the same??? I'll try to create a debug-log, but often in addition the IDE freezes and never returns. I cannot even kill the child nor the debugger in that case, I have to kill the C::B instance running the debugger.

OS: WinXP-SP3, Compiler: TDM 4.5.2, Debugger: "GNU gdb (GDB) 7.2" (also from TDM webpage).
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Issue with step-wise debugging (F7) in debugger branch
« Reply #1 on: August 21, 2011, 03:49:03 pm »
Can you try a debug version of C::B and when it locks to attach a gdb to it and see where it has locked itself?

I have  (almost) no locks or crashes related to the debugger, only CC crashes...

This is on Linux, on windows7 is very bad story, but I'm not sure what it is causing it.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Issue with step-wise debugging (F7) in debugger branch
« Reply #2 on: August 21, 2011, 04:09:38 pm »
Can you try a debug version of C::B and when it locks to attach a gdb to it and see where it has locked itself?
How? Using another C::B instance?
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Issue with step-wise debugging (F7) in debugger branch
« Reply #3 on: August 21, 2011, 05:17:45 pm »
Yes or using gdb directly from the command line.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Issue with step-wise debugging (F7) in debugger branch
« Reply #4 on: September 01, 2011, 04:51:56 pm »
Stepwise debugging ("next line", F7) seems not to work for me anymore or at least works not reliable. Whenever I hit "F7" is sometimes steps to the next line in the code, but then suddenly somewhere completely different - sometimes it steps deeper into the code, sometimes it seems to step out.
I've seen this on optimized code, but I think this is normal and this is GDB feature, than something broken in C::B
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
Re: Issue with step-wise debugging (F7) in debugger branch
« Reply #5 on: September 02, 2011, 09:37:49 am »
I've seen this on optimized code, [...]
The debug code is not optimised. I always have a special debug target with optimisations turned off and debug symbols turned on. So this most likely isn't the case here.

In the moment I am not debugging though... (my code is error free... for the moment... ;-)).
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Issue with step-wise debugging (F7) in debugger branch
« Reply #6 on: September 02, 2011, 09:55:15 am »
OK, next time you see it, please inspect the debug log, but I highly doubt there is something broken in this part of the debugger :)
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]