// the find
agerasev/ringbuf
Lock-free SPSC FIFO ring buffer with direct access to inner data
A lock-free SPSC ring buffer for Rust with zero-copy access to internal memory. Handles arbitrary types (not just Copy), works in no_std/no_alloc environments, and splits cleanly into a Producer/Consumer pair. Aimed at real-time, embedded, and audio/DSP workloads where you need inter-thread data flow without locking.
Direct access to internal ring buffer memory avoids unnecessary copying — useful for I/O and zero-copy pipelines. The frozen/caching wrappers let you batch reads and writes with a single atomic sync instead of one per item, which matters in tight loops. Static variant works on microcontrollers with no heap. The trait abstraction is well-designed: LocalRb, SharedRb, and custom storage all share the same interface.
Strictly SPSC — if you need MPSC or MPMC, you're on your own; the README doesn't mention alternatives or composition patterns. The overwrite mode requires exclusive access, so it can't be used lock-free in concurrent contexts, which is a real footgun given the repo's positioning. The async and blocking crates live in the same monorepo but as separate crates with their own versioning, which makes it easy to pin mismatched versions. Miri is used in CI but only via a shell script, not integrated into the standard test matrix — so unsoundness could slip through on non-Miri runs.