diff options
Diffstat (limited to 'tools/memory-model/litmus-tests/SB+mbonceonces.litmus')
-rw-r--r-- | tools/memory-model/litmus-tests/SB+mbonceonces.litmus | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tools/memory-model/litmus-tests/SB+mbonceonces.litmus b/tools/memory-model/litmus-tests/SB+mbonceonces.litmus new file mode 100644 index 000000000000..b76caa5af1af --- /dev/null +++ b/tools/memory-model/litmus-tests/SB+mbonceonces.litmus @@ -0,0 +1,23 @@ +C SB+mbonceonces + +{} + +P0(int *x, int *y) +{ + int r0; + + WRITE_ONCE(*x, 1); + smp_mb(); + r0 = READ_ONCE(*y); +} + +P1(int *x, int *y) +{ + int r0; + + WRITE_ONCE(*y, 1); + smp_mb(); + r0 = READ_ONCE(*x); +} + +exists (0:r0=0 /\ 1:r0=0) |