diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.target/aarch64/atomic-op-seq_cst.x')
-rw-r--r-- | gcc-4.9/gcc/testsuite/gcc.target/aarch64/atomic-op-seq_cst.x | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.target/aarch64/atomic-op-seq_cst.x b/gcc-4.9/gcc/testsuite/gcc.target/aarch64/atomic-op-seq_cst.x new file mode 100644 index 000000000..e654a74e2 --- /dev/null +++ b/gcc-4.9/gcc/testsuite/gcc.target/aarch64/atomic-op-seq_cst.x @@ -0,0 +1,37 @@ +int v = 0; + +int +atomic_fetch_add_SEQ_CST (int a) +{ + return __atomic_fetch_add (&v, a, __ATOMIC_SEQ_CST); +} + +int +atomic_fetch_sub_SEQ_CST (int a) +{ + return __atomic_fetch_sub (&v, a, __ATOMIC_SEQ_CST); +} + +int +atomic_fetch_and_SEQ_CST (int a) +{ + return __atomic_fetch_and (&v, a, __ATOMIC_SEQ_CST); +} + +int +atomic_fetch_nand_SEQ_CST (int a) +{ + return __atomic_fetch_nand (&v, a, __ATOMIC_SEQ_CST); +} + +int +atomic_fetch_xor_SEQ_CST (int a) +{ + return __atomic_fetch_xor (&v, a, __ATOMIC_SEQ_CST); +} + +int +atomic_fetch_or_SEQ_CST (int a) +{ + return __atomic_fetch_or (&v, a, __ATOMIC_SEQ_CST); +} |