News for hackers. Stuff that matters.
Re:Spinning around: Please don't – Common problems with spin... by Lectem on Thursday January 29, 2026 @12:18AM (#46806093)
> which themselves do a short userspace spin-wait and then fall back to a kernel wait queue on contention.

Yes, but sadly not all implementations... The point remains that you should prefer OS primitives when you can, profile first, reduce contention, and then only, maybe, if you reeeally know what you're doing, on a system you mostly know and control, then perhaps you may start doing it yourself. And if you do, the fallback under contention must be the OS primitive

There are no comments on this comment yet.