Systems Programming · Cluster
Systems Debugging
Core dumps, strace, and sanitizers.
- 01 What an ELF Core File Preserves of a Process How the kernel encodes a dead process as an ELF object: loadable segments for memory, note records for registers and mappings, and what the dump deliberately leaves out.
- 02 From Page Fault to Signal: How SIGSEGV and SIGBUS Differ The kernel path that turns a bad memory access into a signal, why a missing mapping and an unbacked page produce different signals, and what siginfo tells a handler.
- 03 How strace Sees Every System Call Without Linking Into the Program The ptrace stop protocol behind syscall tracing, how entry and exit are paired from register state, and why tracing multiplies the cost of a syscall-heavy workload.
- 04 DWARF Line Tables and How an Address Becomes a Source Line The line-number program is a bytecode that reconstructs a table of address ranges to file, line, and column, and its sequence structure explains why lookups are not simple binary searches.
- 05 Stack Unwinding Without Frame Pointers: Call Frame Information How a debugger or profiler recovers caller frames from a stripped, optimised stack by interpreting DWARF CFI rules instead of walking a saved frame pointer chain.
- 06 Build Identifiers and Separate Debug Information How a 160-bit hash in a note section binds a stripped binary to its symbols, and how debuggers find the matching file through debuglink paths and symbol servers.
- 07 AddressSanitizer Shadow Memory and the Cost of Byte-Granular Checks How one byte of shadow per eight bytes of address space turns every load and store into a checked access, and what redzones, quarantine, and poisoning can and cannot detect.
- 08 Definedness Tracking: What Valgrind Memcheck Knows That Shadow Bytes Do Not Memcheck runs the program on a synthetic CPU and carries a definedness bit per bit of data, catching reads of uninitialised memory that address-based checks cannot see.
- 09 Data Race Detection with Vector Clocks and Happens-Before Order How ThreadSanitizer replaces happens-before with vector clocks per memory access, why the shadow word costs eight bytes per four, and where the ordering it assumes is wrong.
- 10 Deterministic Replay: Recording a Thread Schedule and Playing It Back What must be captured to reproduce an execution exactly, why recording the interleaving is not enough, and how replay trades observability for the ability to repeat a failure.