-
Notifications
You must be signed in to change notification settings - Fork 385
Add missing atomic_fence intrinsics as nops #979
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Please add a test calling the stable function from std::sync, so we have some code actually invoking these intrinsics |
Would adding a function like atomic_fences to https://github.com/rust-lang/miri/blob/master/tests/run-pass/atomic.rs using https://doc.rust-lang.org/std/sync/atomic/fn.fence.html with all Orderings be enough? |
Yes, definitely |
Force pushed, fence(Relaxed) panics (https://doc.rust-lang.org/std/sync/atomic/fn.fence.html#panics) so trying to test that was a bad idea |
@bors r+ |
📌 Commit bd4a299 has been approved by |
Add missing atomic_fence intrinsics as nops Fixes #972
☀️ Test successful - checks-travis, status-appveyor |
fn atomic_fences() { | ||
fence(SeqCst); | ||
fence(Release); | ||
fence(Acquire); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This tests 3 fences but you added 4 intrinsics... I will add a test for the AcqRel
ordering.
also test AcqRel fence Missing from #979
Fixes #972