Disable code optimization for Debug target

Sysprogs forums Forums VisualGDB Disable code optimization for Debug target

This topic contains 1 reply, has 1 voice, and was last updated by  hfrmobile 2 months, 2 weeks ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #10012

    hfrmobile
    Participant

    In my point of view it would be helpful when debugging to disable code optimization since when I debug an VisualGDB application  it is jumping like a “crazy horse through” the code …

    In the VisualGDB project settings I added the -O0 (disable code optimizations completely) but it doesn’t change anything.

    Useful tips but not what I am looking for at the moment: http://visualgdb.com/debugging/

    Example: pDevice == NULL:

     

    Breakpoint at 49:
    47, 51, 55, 51, 57

    Or is there something wrong with my settings?

     

    #10016

    hfrmobile
    Participant

    After adding -O0 to the “Common flags” (Debug target) and a rebuild the problem is gone!

     

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.