|
libe3 0.2.5
C++ library for E3AP RAN vendor integration
|
Lock-free bounded Multi-Producer Multi-Consumer (MPMC) ring buffer. More...
#include <atomic>#include <cstddef>#include <new>Go to the source code of this file.
Classes | |
| class | libe3::MpmcQueue< T > |
| Lock-free bounded MPMC ring buffer. More... | |
Namespaces | |
| namespace | libe3 |
Functions | |
| void | libe3::cpu_relax () noexcept |
| Emit a CPU-level pause/yield hint inside spin-wait loops. | |
Variables | |
| static constexpr size_t | libe3::CACHE_LINE_SIZE = 64 |
| Assumed cache-line size (bytes) used for alignment padding. | |
Lock-free bounded Multi-Producer Multi-Consumer (MPMC) ring buffer.
Implements Dmitry Vyukov's MPMC bounded queue algorithm. Each slot carries an atomic sequence counter that acts as a generation tag, eliminating the need for CAS on the data itself and making the queue safe for any number of concurrent producers and consumers with very low overhead.
Design highlights:
SPDX-FileCopyrightText: Copyright (c) 2026 Northeastern University SPDX-License-Identifier: Apache-2.0
Definition in file mpmc_queue.hpp.