-
Notifications
You must be signed in to change notification settings - Fork 301
Fixes for non-temporal intrinsics #1929
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
|
Can you add a comment explaining why inline asm is used here? |
|
Shouldn't the implementation of |
|
My understanding is that x86 memory model weirdness only applies to non-temporal stores, not non-temporal loads. |
|
SDM says
and
so it seems like this can be UB if some very specific conditions are met (I am not too good with memory types). Do we not support such things (like using different memory types for same chunk in different processors)? It still seems like the second condition (syncing with other agents) might be a vulnerability |
|
Memory type is an attribute that the OS sets for a range of physical memory. Normal memory uses the WB protocol which has the expected memory ordering semantics. Essentially we don't consider WC memory as normal memory for the Rust abstract machine, so the condition doesn't apply here. |
_mm_stream_{ss,sd}_mm_sfencecalls in tests, without it the tests are technically UB