Add compiler fences to test

This commit is contained in:
David Cook 2020-01-25 13:48:26 -06:00
parent 625fa742bc
commit 9265e0cd5e

View file

@ -1,4 +1,4 @@
use std::sync::atomic::{fence, AtomicBool, AtomicIsize, AtomicU64, Ordering::*};
use std::sync::atomic::{compiler_fence, fence, AtomicBool, AtomicIsize, AtomicU64, Ordering::*};
fn main() {
atomic_bool();
@ -70,4 +70,8 @@ fn atomic_fences() {
fence(Release);
fence(Acquire);
fence(AcqRel);
compiler_fence(SeqCst);
compiler_fence(Release);
compiler_fence(Acquire);
compiler_fence(AcqRel);
}