Correctness under concurrent execution

Build concurrency arguments from happens-before relations, linearization points, reclamation, and explicit progress guarantees.

10 published lessons1 module245 min of guided study
  1. 01
    Correctness under concurrent executionadvanced · 10 lessons

Follow the path or begin with a question. Every lesson is open.

Your notebook0 of 10 lessons completed

Your place, at your pace. Progress is optional and saved only in this browser when available.

Inside this module

Each lesson includes an interactive lab

Correctness under concurrent execution

Build concurrency arguments from happens-before relations, linearization points, reclamation, and explicit progress guarantees.

  1. 01

    Data races: draw the ordering argument

    Build a happens-before graph for shared data and distinguish language-level undefined behavior from an ordinary timing-dependent result.

    23 min
  2. 02

    Mutexes and condition variables: protect a predicate

    Design a blocking queue around protected state, repeated predicate checks, orderly shutdown, and an explicit lock-order argument.

    24 min
  3. 03

    Atomics: indivisibility is only one guarantee

    Separate atomic read-modify-write behavior from publication ordering and choose memory orders from a documented proof.

    25 min
  4. 04

    Compare-and-swap: equal bits can hide changed history

    Trace CAS success and failure, distinguish weak spurious failure from interference, and expose ABA and lifetime hazards.

    25 min
  5. 05

    Linearizability and progress: two different promises

    Check a concurrent history against a sequential contract and distinguish blocking, obstruction-free, lock-free, and wait-free behavior.

    26 min
  6. 06

    Lock-free queues and ring buffers

    Separate slot ownership, payload publication, and progress guarantees when designing concurrent FIFO structures.

    24 min
  7. 07

    Hazard pointers and epoch reclamation

    Decide when a removed concurrent node can be reclaimed without invalidating readers that still hold references.

    24 min
  8. 08

    Read-copy-update principles

    Separate publication, removal, grace-period detection, and reclamation in read-mostly concurrent structures.

    24 min
  9. 09

    Work stealing and task scheduling

    Relate owner/thief deque protocols to work, span, and the limits of parallel task scheduling.

    24 min
  10. 10

    Concurrency testing and schedule exploration

    Build small concurrent test harnesses, enumerate meaningful executions, and state exactly what passing exploration establishes.

    26 min
All engineering modules