Internal Architecture of Delve, a Debugger For Go
summary
Delve is a Go-written symbolic debugger with a three-layer design: a target/proc layer that uses proc/native (ptrace/waitfor debug event/exception ports) or proc/gdbserial to connect to rr or debugserver, a symbolic layer that reads DWARF sections (.debug_info, .debug_line, .debug_frame) and a headless UI communicating over JSON‑RPC/TCP. It handles Go-specific problems: goroutine stacks can move when morestack runs, so breakpoints skip the prologue; variable evaluation reads memory then decodes types; next/step-over uses conditional breakpoints checking goroutine identity and stack frame to avoid concurrency and recursion traps.
AI-written summary · about
chapters (18)
- 0:00Intro
- 1:10What is This
- 2:15CPU
- 4:22Call Stack
- 10:02Target Layer in Delve (3)
- 16:20DWARF Sections (1)
- 17:44debug_info example (2)
- 20:06Stacktraces
- 20:26Symbolic Layer in Delve
- 20:46Actual Architecture of Delve (2)
- 21:46User Interfaces for Delve
- 22:18Actual Architecture of Delve (3)
- 24:01Variable Evaluation gdb vs delve
- 24:56Creating Breakpoints
- 29:08Wrong "next" strategy, step 3
- 30:01Wrong "next" strategy, bug 2
- 31:44Wrong "next" strategy, bug 1: Can't handle concurrency
- 32:13Better "next" strategy








