Open
Description
Expose LLVM's "element wise atomic memory intrinsics". In particular:
- Expose
llvm.memcpy.element.unordered.atomic
asatomic_element_unordered_copy_memory_nonoverlapping
- Expose
llvm.memmove.element.unordered.atomic
asatomic_element_unordered_copy_memory
- Expose
llvm.memset.element.unordered.atomic
asatomic_element_unordered_set_memory
Expose these through functions in the std::ptr
module. Each function is implemented by the equivalent intrinsic or by a loop of relaxed atomic operations if the intrinsic is not available on the target platform (TODO: Given this platform-specific behavior, can this also be exposed in core::ptr
?)
copy_nonoverlapping_atomic_unordered
, backed byatomic_element_unordered_copy_memory_nonoverlapping
copy_atomic_unordered
, backed byatomic_element_unordered_copy_memory
write_atomic_unordered
, backed byatomic_element_unordered_set_memory
Previously discussed on the internals forum here.
Folks with the authority to approve this: Let me know if this is OK to move forward; I'd like to post it to This Week in Rust's CFP.
Metadata
Metadata
Assignees
Labels
Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues.Area: Atomics, barriers, and sync primitivesCategory: A feature request, i.e: not implemented / a PR.Relevant to the language team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.