Debug C++ Programs You did not write
summary
Debugging C++ binaries without source proves practical: retrieve debuginfod / public symbol servers for OpenJDK nightlies, but optimizer still hides values; decompile with Ghidra (decompile to C) and map parameters to registers to find addresses; instrument the loaded shared object with Frida to inject fast runtime prints and unlimited hardware breakpoints via page-protection, which reliably logs values in the JVM; GDB record/trace and gdb-based tracing fail to scale on large multithreaded targets. The injected traces expose the wrong pointer use and enable a confirmed workaround.
AI-written summary · about
chapters (15)
- 0:00Introduction to debugging
- 1:08Compiler errors and workarounds
- 2:55Debugging external libraries
- 3:58Finding debug symbols
- 5:43Using debug symbols with GDB
- 7:30Debug info limitations
- 8:11Ground truth and register values
- 10:20Failed debugging attempts
- 11:46Automated breakpoints and slowness
- 12:47Decompilation approach
- 15:18Tracing with Frida
- 17:26Dynamic module instrumentation
- 19:11Hardware breakpoints with Frida
- 20:34Planning and debugging strategies
- 21:41Q&A and wrap-up
