Topic domain

Memory Systems

Address spaces, allocators, and the cost of touching memory.

Articles
80
Clusters
8
Foundational
24
Intermediate
32
Advanced
24

Paging, address translation, and page tables.

  1. Splitting a Virtual Address into Page Number and Offset
  2. Walking a Multi-Level Page Table
  3. The TLB, Associativity, and What a Miss Actually Costs
  4. Demand Paging and the First-Touch Fault
  5. Clock, Second Chance, and the Cost of Approximating LRU
  6. Large Pages: What 2 MiB Granularity Buys and What It Breaks
All 10 in this cluster →

Arena, slab, and general-purpose heap design.

  1. Bump Allocation and the Cost of Arena Reset
  2. Boundary Tags and Coalescing in a Free-List Heap
  3. Size-Class Segregation and Fit Policy in the Heap
  4. Slab Caches and Per-CPU Magazines for Fixed-Size Objects
  5. Thread-Local Caches and the Cost of a Remote Free
  6. How free Recovers a Size From a Bare Pointer
All 10 in this cluster →

Locality, coherence, and replacement.

  1. The Memory Gap and the Arithmetic of Average Access Time
  2. Set Associativity and the Address Bits a Cache Decodes
  3. Write-Back, Write-Through, and the Cost of a Dirty Line
  4. Replacement Without Exact LRU: Reference Bits and Clock Hands
  5. Stride Prefetchers and the Timing Problem of Prefetch Distance
  6. MESI Transitions and the Traffic an Invalidation Generates
All 10 in this cluster →

Remote access costs and placement policy.

  1. Node Distance and the Real Cost of a Remote Memory Access
  2. Reading NUMA Topology from the SRAT and SLIT
  3. First-Touch Placement and the Faulting Thread
  4. CPU Affinity Masks and What Pinning Actually Costs
  5. Interleaving Pages Across Nodes for Aggregate Bandwidth
  6. Where a Memory Policy Attaches and How It Inherits
All 10 in this cluster →

Bounds, use-after-free, and mitigation strategies.

  1. How an Out-of-Bounds Write Reaches Allocator Metadata
  2. Use-After-Free and the Reuse That Conceals It
  3. Stack Canaries and What They Actually Detect
  4. Double Free and the Integrity of Free Lists
  5. AddressSanitizer and the Arithmetic of Shadow Memory
  6. Slice Bounds Checks and the Conditions for Eliding Them
All 10 in this cluster →

Durability semantics and crash consistency.

  1. A Completed Write Is Not Yet Durable: Persistence Domains and Ordering
  2. What fsync Actually Waits For, and Why the Directory Counts
  3. Cache Flushes and FUA: The Two Ordering Primitives Below the Filesystem
  4. Write-Ahead Logging and the Commit Record
  5. Checkpointing and the Cost of a Consistent Snapshot
  6. Shadow Paging and Copy-on-Write Trees
All 10 in this cluster →

Formal models of reads, writes, and ordering.

  1. Sequential Consistency as the Reference Memory Model
  2. Store Buffers and the x86-TSO Model
  3. Happens-Before and the Definition of a Data Race
  4. Coherence and the Modification Order of a Single Location
  5. Release, Acquire, and the Synchronizes-With Edge
  6. The DRF-SC Guarantee and What It Buys a Programmer
All 10 in this cluster →

Leak detection, fragmentation, and footprint analysis.

  1. Reading a Process Footprint: RSS, PSS, and Shared Pages
  2. Interposing on malloc: How Allocation Tracing Hooks a Heap
  3. Attributing Allocations to Call Sites by Unwinding the Stack
  4. Reachability, Retention, and What Counts as a Leak
  5. Allocator Metadata and the Real Cost of a Small Object
  6. Measuring Fragmentation: Free Space That Cannot Be Used
All 10 in this cluster →

All Memory Systems articles