Skip to content
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

Implement sequentially consistent memory ordering for strong references #3

Open
lorentey opened this issue Oct 2, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@lorentey
Copy link
Member

lorentey commented Oct 2, 2020

To simplify the initial implementation, atomic references currently treat all orderings as acquire/release, including .sequentiallyConsistent. This isn't tenable -- they should at least differentiate between acquire/release and sequentially consistent orderings. Supporting relaxed ordering is less crucial, given that strong references already involve some amount of memory fences.

Note that we don't want to inline the strong reference implementation into user code, so internally each supported ordering must be mapped to its own set of independent entry points. Unfortunately, this will likely involve a measure of code generation. (Another option would be to use relaxed operations and add appropriate fences.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant