Debugging with breakpoints

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Is there any way of continue running the program after reaching a breakpoint without having to disable it?

   

I want to check my values in a loop and stop every time it reaches the breakpoint.

   

But right now I have to:

   

* disable the breakpoint

   

* set a new secondary breakpoint one further in the code

   

* run the code to it

   

* re-enable my original breakpoint

   

* disable the secondary breakpoint

   

* finally, run the code to stop where I really want !

   

It must be a better way of doing that!

0 Likes
1 Solution
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Welcome in the forum!

   

In short: Reaching a breakpoint stops the CPU only, the hardware keeps on running, thus generating interrupts.

   

When continuing, the interrupt gets handled and returns --- to your breakpoint and execution stops.

   

So disable interrupts while single-stepping parts of your code, there is an icon you may use for a single click.

   

 

   

Happy coding

   

Bob

View solution in original post

0 Likes
1 Reply
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

Welcome in the forum!

   

In short: Reaching a breakpoint stops the CPU only, the hardware keeps on running, thus generating interrupts.

   

When continuing, the interrupt gets handled and returns --- to your breakpoint and execution stops.

   

So disable interrupts while single-stepping parts of your code, there is an icon you may use for a single click.

   

 

   

Happy coding

   

Bob

0 Likes