
Hi Mike,
On Wed, Jul 3, 2013 at 5:40 AM, Mike Dunn mikedunn@newsguy.com wrote:
On 07/01/2013 12:51 PM, Wolfgang Denk wrote:
Dear Mike Dunn,
In message 51D1C455.9010801@newsguy.com you wrote:
But there's a good motivation for wanting to turn off optimization.
I disagree here. If you are hunting down a problem, you want to be as close at the original code as possible. Disabling optimization is such a dramatic change to the generated code that you actually debug a different program.
I guess it depends on what problem being debugged... I think your point is valid for things like tracking down race conditions or misbehaving hardware. But for more mundane problems like logical errors in the code, optimizations get in the way. It would be nice to be able to experiment with optimizations off. Just knowing that a particular problem still exists when unoptimized code is run will provide some clues.
Do be honest, I have never used an online debugger
I have always found that a combination of hardware LEDs and printf's has been more than sufficient, particularly for mundane issues.
I'll freely admit that an online debugger might been faster for me, but I just wanted to point out that there is more than one way to skin a cat.
I also believe that the more onerous the debugging tool is (and it doesn't get more so than using the hardware LEDs) the more attention you pay to the code rather than the output ;)
Regards,
Graeme