ZView: Non-Intrusive Runtime Observability for Zephyr
summary
Live tool that reads kernel memory via SWD and turns raw Elf/DWARF offsets into a TUI showing threads, stack watermarks, heap allocations and fragmentation, mutex/semaphore/queue/slab states, and CPU load, using OpenOCD/J‑Link/GDB backends. It does no halt, no instrumentation on Cortex‑M boards (STM32, nRF, RP2040 tested), defaults to 100 ms sampling (configurable), records compact JSON for replay/CI, and costs nothing unless extra Kconfig flags are required. Limitations: not a tracer (short events can be missed), needs statically discoverable objects and untested on cached or multi‑core systems.
AI-written summary · about
chapters (20)
- 0:00Introduction to ZView
- 1:26Debugging challenges with Zephyr
- 4:16Frame buffer debugging inspiration
- 6:45Introducing ZView concept
- 7:26Stack watermarks and CPU load tracking
- 8:54Heap fragmentation visualization
- 10:40Recording and replaying debugging sessions
- 11:45JSON dump for CI and AI integration
- 12:48Kernel objects monitoring
- 14:56Build checks and memory map validation
- 15:59Declaration site tracking
- 16:41Cost and build impact of ZView
- 18:27How ZView reads memory without halting
- 20:56Compatibility across Zephyr versions
- 22:01ZView architecture overview
- 23:06Limitations and differences from tracing
- 25:34Discovery of dynamic objects
- 26:38Contributions and community growth
- 26:59Future plans for ZView
- 28:23Call to action and Q&A
