Building a Fast Lock-Free Queue in Modern C++ from Scratch
Summary
A guide to implementing a fast lock-free queue in modern C++, covering techniques for concurrent data structures without locks.
Similar Articles
Girls Just Wanna Have Fast MPMC Queues with Bounded Waiting
A technical blog post detailing the design and implementation of a lock-free MPMC queue with bounded waiting, including theory, advantages, limitations, and benchmark comparisons.
Your code is fast – if you're lucky
This article presents a branchless Quicksort implementation using sorting networks and discusses how modern compilers, especially Clang, optimize loops with branch-free instructions when written in the right style.
Efficient C++ Programming for Modern C++ CPUs, Chapter 4/part 2
This draft book chapter provides an infographic and detailed analysis of operation costs in CPU clock cycles for modern C++ CPUs, covering multiplication, division, and RTTI with latency tables for various architectures.
const_cast: A Necessary Evil
The article explains why const_cast is sometimes necessary in C++, specifically for moving objects out of a std::priority_queue, and how to do it safely.
Neoclassical C++: segmented iterators revisited
Revisits Matt Austern's 2000 paper on segmented iterators, which enable hierarchical algorithms to exploit data structure segmentation for performance, and discusses modern adoption in libc++ and Boost libraries.