It might be easier to read that first, as it also goes into practical applications, and then this one.
jeffbee 1 hours ago [-]
I can't help myself digging into the referenced source code. The membarrier syscall can fail to allocate, returning ENOMEM. The way Folly calls it, the program would abort. Which I guess is a fair strategy but it's good to know when your synchronization primitive is actually SynchronizeOrCrash.
nttylock 3 hours ago [-]
[flagged]
Rendered at 17:17:50 GMT+0000 (Coordinated Universal Time) with Vercel.
For me, the reading that made asymmetric fences "click" is this: https://pvk.ca/Blog/2019/01/09/preemption-is-gc-for-memory-r...
It might be easier to read that first, as it also goes into practical applications, and then this one.