Re: GDB and ARM Frame Pointer strangeness

Andrew Cagney
2004-06-09T15:14:04Z

> Everything might be ok, if you are using a software interface that you have "burned and learned" to get executing and which has set up your environment for you, but we have the ability to debug right from a hardware reset, the registers are in this state completley random. There is no ABI in use, and it is inapproriate for GDB to "assume" at this stage that it can dereference R11 and that that register contains the frame pointer.

There's nothing special about the state of the inferior immediatly after
a reset. R11 (just like any other register) could become corrupt at any
moment in the program's execution, and equally could always be valid
after a reset.

Also, there's nothing special about the debugger generating apparently
random memory fetches. Such a fetch could equally come from the user
(e.g., via a typo), the target must be robust to such accesses (there is
the "mem" command to help with this).

Andrew