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

Incorrect Statement about What is Impossible #449

Open
pl170491 opened this issue Apr 28, 2024 · 0 comments
Open

Incorrect Statement about What is Impossible #449

pl170491 opened this issue Apr 28, 2024 · 0 comments

Comments

@pl170491
Copy link

In the chapter about Atomics (Chapter 8.3 sub-section "Data Accesses") there is a very strong statement made about the possibility of synchronizing data between any two or more threads using only normal (i.e. non-atomic) data accesses. I believe there exists an algorithm for sharing data between two threads deterministically and correctly without the use of any atomic operations, and it works even on weakly ordered hardware (or at least so far I've tested it on Apple M3 which is ARM based, as well as the more strongly ordered Intel x86/64). As such, assuming I'm not utterly mistaken, I'd like to request that this statement be altered to better describe reality:

"It is literally impossible to write correct synchronized code using only data accesses."

The code is located here if you're interested in testing it to prove to yourself that what I say is true on your personal hardware.
https://github.com/alareti/fallout

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

No branches or pull requests

1 participant