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

Instruction and Data Fault registers

I am trying to figure out why my application is generating a hard fault. The hardware platform is nRF52832 and SDK is 17.1.0

In my experience, the generic Cortex M3 processor (and most likely the M4 too) has two registers (DFAR and IFAR) that capture the fault address at run time.

The IFAR usually has the address of the instruction that triggered a 'bad instruction' (or similar) error.
The DFAR usually has the address of the innstruction that caused a bad read or a bad write (only for deterministic, ordered sequence?).
I do not see such a register being exposed when I am debugging with the Segger IDE provided by Nordic.

Is there anything I can set up on the Segger IDE, or perhaps use some other tool, that will allow me to view the faulting address?
NOTE that the fault happens when the application is executing multiple threads asynchronously and it is not easy to 'navigate to the faulting address one line at a time in the debugger'.

Thanks

RMV

Parents
  • Just an update..

    I was able to narrow down the root cause of the failure -- through some random trial and error -- that the issue was because I was using two asynchronous and independent schedulers that were completely disconnected and that led to invalid states in my application later on.

    However, I would still like to understand how I can narrow down the offending instruction that triggered an instruction fetch/decode error or a precise/imprecise data access error.

    Cheers

    RMV

Reply
  • Just an update..

    I was able to narrow down the root cause of the failure -- through some random trial and error -- that the issue was because I was using two asynchronous and independent schedulers that were completely disconnected and that led to invalid states in my application later on.

    However, I would still like to understand how I can narrow down the offending instruction that triggered an instruction fetch/decode error or a precise/imprecise data access error.

    Cheers

    RMV

Children
No Data
Related