Fence Semantics
The rules governing how memory fences restrict the reordering of load and store operations across threads.
A memory fence constrains the CPU to avoid reordering memory operations across the fence. A full fence forbids all reordering; acquire fences (placed after loads) and release fences (placed before stores) allow optimizations while guaranteeing synchronization. Semantics are architecture-specific — x86 is strict, while ARM and POWER are weaker. Languages like C++11 abstract these differences through acquire-release semantics.