github.com/daskol/spinlock (go): Package spinlock provides a low level implementation of spinlock in assembly. Also, it provides fallback to implementation based on built-in atomics.  On my private laptop benchmark results are the following. Measured time is wall time.  The fastest implementation based on free function Lock()/Unlock(). However it is two times slower than spinlock implemented in modern C++.
Keywords: amd64|assembler|assembly|cas|golang|spinlock