This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Why is the debugger hanging?

Hi

I'm writing my first ARM application. I have C++ code that works in Visual Studio on Windows and I am porting it to ARM using ARM Dev Studio. I want to target Cortex M6 but am currently targeting Cortex-A53 as that is suggested in the tutorial.  My code builds ok and runs ok in the debugger up to a certain point, at which the debugger hangs when I try to step over the next line:

It seems to be a consequence of accessing the pointer rather than the cout. Earlier cout's work ok. I think the pointer is valid.

Please can you help me find out why this is happening? I don't know what to do next.

Thanks

David

Parents
  • Hi David,

    To see which instruction causes the exception, you should either single-step at instruction level and watch the Disassembly view on each step,
    or run (not step) to the exception trap and then look at the instructions in the Trace view.

    From the output you gave, it looks like the instruction at/near 0x8000A40C is the culprit.

    In the screenshot below, using the startup_Armv8-Ax1_GCC (where I've deliberately changed SP to an invalid value), the Trace is showing that the STP instruction at 0x80003170 caused the exception.

    Stephen

Reply
  • Hi David,

    To see which instruction causes the exception, you should either single-step at instruction level and watch the Disassembly view on each step,
    or run (not step) to the exception trap and then look at the instructions in the Trace view.

    From the output you gave, it looks like the instruction at/near 0x8000A40C is the culprit.

    In the screenshot below, using the startup_Armv8-Ax1_GCC (where I've deliberately changed SP to an invalid value), the Trace is showing that the STP instruction at 0x80003170 caused the exception.

    Stephen

Children