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

AtomicWaker: store, not swap if old value is not used #1314

Closed
wants to merge 1 commit into from

Conversation

stepancheg
Copy link
Contributor

No description provided.

@stepancheg
Copy link
Contributor Author

cc @Pslydhh

@Pslydhh
Copy link
Contributor

Pslydhh commented Nov 6, 2018

Thanks!
I'm completely agress with you here semantically speaking swap is more suitable than store.
but maybe the question is about memory's synchronize, a long conversation about this show that swap is suitable choice in mutiple threads and architectures(not only x86), store is not.
use store
store can't acquire
use swap instead store

@stepancheg
Copy link
Contributor Author

@Pslydhh thank you for the links!

@stepancheg stepancheg closed this Nov 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants