Adventures with Memory Barriers and Seastar on Linux

Introduction

Seastar Inter-thread Communication Backgrounder

Basic Lock-free Single-producer/Single-consumer Queues

The Complications of Sleeping

Moving Work to Idle Cores

Injecting Barriers with mprotect()

Not So Fast

membarrier() to the Rescue

Performance Evaluation

Conclusion

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store