<atomic> enums

Visual Studio 2015
 

The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.

The latest version of this topic can be found at <atomic> enums.

memory_order Enum](#memory_order_enum)|

Supplies symbolic names for synchronization operations on memory locations. These operations affect how assignments in one thread become visible in another.

typedef enum memory_order {
    memory_order_relaxed,
 memory_order_consume,
    memory_order_acquire,
 memory_order_release,
    memory_order_acq_rel,
 memory_order_seq_cst,
} memory_order;

Remarks

memory_order_relaxedNo ordering required.
memory_order_consumeA load operation acts as a consume operation on the memory location.
memory_order_acquireA load operation acts as an acquire operation on the memory location.
memory_order_releaseA store operation acts as a release operation on the memory location.
memory_order_acq_relCombines memory_order_acquire and memory_order_release.
memory_order_seq_cstCombines memory_order_acquire and memory_order_release. Memory accesses that are marked as memory_order_seq_cst must be sequentially consistent.

<atomic>

Show: