News for hackers. Stuff that matters.
Re:Proposed futex2 allows Linux to mimic the NT kernel for b... by e_proxus on Wednesday April 28, 2021 @03:24PM (#26973067)
But it can’t be turtles all the way down? Isn’t a semaphore counter also shared state that needs to be protected if several threads want to “down” the value? Can it become negative?
Re:Proposed futex2 allows Linux to mimic the NT kernel for b... by gpderetta on Wednesday April 28, 2021 @03:41PM (#26973245)
Well at the bottom of the turtle stack you have harware primitives that guarantee atomicity of a bunch of word sized arithmetic operations (at the minimum CAS or LL/SC).