~/talk

How Debuggers Work

Talkat Pure Virtual C++ 2025 · on Wednesday, 2025-04-30· [c-and-cpp]
name:Sy Brand
slides:none on file

Covers how native debuggers on Linux map DWARF data to running code, read memory with ptrace PEEKDATA returning 64 bits, and set breakpoints either by writing 0xCC INT3 into code or using hardware watchpoints limited to four debug registers on x64. Shows how variable bytes are interpreted from DWARF type info, how a debugger fabricates calls via the platform ABI, and describes dynamic debugging that swaps optimized functions for unoptimized copies to restore stepping and visibility.

AI-written summary · about

  1. 0:00Intro
  2. 0:33What kind of debugger
  3. 1:10Agenda
  4. 1:43Debug Scenario Architecture
  5. 3:33Memory Manipulation
  6. 4:25Prace
  7. 6:08Setting a breakpoint
  8. 13:13Reading a variable
  9. 15:53Calling a function
  10. 17:51Debugging optimized code
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.