Loading...
 
Skip to main content

System Workbench for STM32


Breakpoint at the wrong line

Something is wrong with the previous answers.

The optimization option (-O) has a number (0-3). As the number increases, the optimization that the compiler does increases.

When debugging, you want to turn the optimization off (-O0).

When you release your code you want to test and release with higher levels of optimization (-O3).

If your toolchain is set with debug set to 3 and release set to 0, that's just wrong.

Andrei