[KongchangAI]
ConceptCAS / compare-and-swap

Compare-and-Swap

A hardware atomic operation primitive that atomically compares a memory value with an expected value and, if they are equal, writes a new value and returns the old value; it is the foundation for building lock-free data structures and spin locks.

Timeline (last 90 days)

Nov 12

The implementation of spinlocks relies on the compare-and-swap atomic operation provided by the hardware.

Unverified50%

All Facts (1)

Source Articles