Does anyone have any source code for handling abort exceptions and doing some stack backtracing? I'm using the keil compiler, and the supplied functions for Undefined Instruction, Prefetch Abort, and Data Abort exceptions just sit in a while loop. I'd like to extract and dump the offending program counter and a call stack. I've also read about APCS - ARM Procedure Call Standard. Does the Keil compiler use this? Thanks.
Please take a look to: http://www.keil.com/support/docs/3080.htm CARM follows closely the APCS, but is not 100% compatible for struct passing.
I've done that, where I get the offending address from R14. I was looking for additional code to backtrace through the stack to get some idea of the execution path leading up to the abort. For example, if the data abort comes from the printf function, that's not much help, since printf is called all over the place. I want to find out who called printf. Thanks, MW