summaryrefslogtreecommitdiff
path: root/src/stdatomic/atomic_thread_fence.c
blob: ee26a2600ff678a21ea5098cf38682a8c88157d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#include <stdatomic.h>

void atomic_thread_fence(memory_order order)
{
	switch (order) {
	case memory_order_relaxed:
		break;

	case memory_order_acquire:
	case memory_order_consume:
		/* acquire fence */
		break;

	case memory_order_release:
		/* release fence */
		break;

	case memory_order_acq_rel:
		/* acquire fence and release fence */
		break;

	case memory_order_seq_cst:
		/* sequentially consistent acquire and release fence */
		break;
	}
}