Debian Codegraph @

gcc/testsuite/gcc.target/aarch64/atomic-comp-swap-release-acquire.x

raw
1
2 #define STRONG 0
3 #define WEAK 1
4 int v = 0;
5
6 int
7 atomic_compare_exchange_STRONG_RELEASE_ACQUIRE (int a, int b)
8 {
9 return __atomic_compare_exchange (&v, &a, &b,
10 STRONG, __ATOMIC_RELEASE,
11 __ATOMIC_ACQUIRE);
12 }
13
14 int
15 atomic_compare_exchange_WEAK_RELEASE_ACQUIRE (int a, int b)
16 {
17 return __atomic_compare_exchange (&v, &a, &b,
18 WEAK, __ATOMIC_RELEASE,
19 __ATOMIC_ACQUIRE);
20 }
21
22 int
23 atomic_compare_exchange_n_STRONG_RELEASE_ACQUIRE (int a, int b)
24 {
25 return __atomic_compare_exchange_n (&v, &a, b,
26 STRONG, __ATOMIC_RELEASE,
27 __ATOMIC_ACQUIRE);
28 }
29
30 int
31 atomic_compare_exchange_n_WEAK_RELEASE_ACQUIRE (int a, int b)
32 {
33 return __atomic_compare_exchange_n (&v, &a, b,
34 WEAK, __ATOMIC_RELEASE,
35 __ATOMIC_ACQUIRE);
36 }