We present Hemlock, a novel mutual exclusion locking algorithm that is extremely compact, requiring just one word per thread plus one word per lock, but which still provides local spinning in most circumstances, high throughput under contention, and low latency in the uncontended case. Hemlock is context-free -- not requiring any information to be passed from a lock operation to the corresponding unlock -- and FIFO. The performance of Hemlock is competitive with and often better than the best scalable spin locks.
翻译:我们展示了Hemlock, 这是一种新型的相互排斥锁定算法, 非常紧凑, 要求每个线条只一个单词加每个锁一个单词, 但是它仍然在多数情况下提供本地旋转, 高通量在争议中, 以及无争议情况下的低延迟。 Hemlock是没有上下文的, 并不要求任何信息从锁定操作传递到相应的解锁。 FIFO 。 Hemlock 的性能比最好的可伸缩的旋转锁更具有竞争力, 并且往往比最好的可伸缩的旋转锁更好 。