Compare-and-Swap · Atomic if-then-write
unseel.com · CAS(ptr, expected, new) · ~10–30 cycles
Memory 5
Retries 0
Stage idle
Shared memory
Thread A (succeed)
Thread B (retry)
ABA — stale view
Unseel.com · Compare-and-Swap