Hardware interview practice
Triage an intermittent firmware hang from a crash dump
A Cortex-M system occasionally trips its watchdog. You have PC=0x08001234, LR=0x08005679, SP=0x20001000, 64 stack bytes, fault registers, a build ID, and the exact ELF/map candidate. Describe a deterministic triage sequence.
Reviewed example
Work through one case
Input
PC maps to queue_pop+0x18 in the matching ELF, but SP=0x10000003 is outside the documented SRAM rangeExpected output
Report queue_pop as the fault site, mark the unwind unreliable, and prioritize stack-corruption and invalid-SP evidenceA symbolized PC is useful even when the stack is bad, but arbitrary stack words must not be presented as a trustworthy call chain.
What to cover
Requirements
- Confirm the dump build ID matches the ELF before symbolizing any address.
- Symbolize PC and LR, decode the exception frame and fault registers, and inspect the faulting instruction and stacked arguments.
- Validate SP range and alignment; unwind only frames supported by valid stack data and identify task versus interrupt context.
- If the evidence is insufficient, add a bounded timestamped flight recorder rather than guessing from an unreliable backtrace.
