8000 [RFC] AtomicPerByte (aka "atomic memcpy") by m-ou-se · Pull Request #3301 · rust-lang/rfcs · GitHub
[go: up one dir, main page]

Skip to content

[RFC] AtomicPerByte (aka "atomic memcpy") #3301

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

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix types of C++ API.
  • Loading branch information
m-ou-se committed Aug 15, 2022
commit eb68c3a6996be0168f44cdb08a0e1b4873e60dde
4 changes: 2 additions & 2 deletions text/3301-atomic-memcpy.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ C++'s [P1478] proposes the addition of these two functions to the C++ standard
library to solve this problem:

```cpp
void atomic_load_per_byte_memcpy(void *dest, void *source, size_t, memory_order);
void atomic_store_per_byte_memcpy(void *dest, void *source, size_t, memory_order);
void *atomic_load_per_byte_memcpy(void *dest, const void *source, size_t, memory_order);
void *atomic_store_per_byte_memcpy(void *dest, const void *source, size_t, memory_order);
```

The first one is effectively a series of `AtomicU8::load`s followed by a memory fence,
Expand Down
0