| Crates.io | atomic_ring_buffer |
| lib.rs | atomic_ring_buffer |
| version | 1.0.0 |
| created_at | 2017-01-31 11:53:18.774841+00 |
| updated_at | 2017-01-31 11:53:18.774841+00 |
| description | A fixed-size multi-producer multi-consumer queue that works on bare-metal systems. |
| homepage | https://github.com/m-labs/atomic_ring_buffer |
| repository | https://github.com/m-labs/atomic_ring_buffer.git |
| max_upload_size | |
| id | 8321 |
| size | 22,402 |
atomic ring buffer is a fixed-size multi-producer multi-consumer queue that works on bare-metal systems. Under certain conditions, the queue is wait-free or lock-free.
See documentation for details.
To use the atomic ring buffer library in your project, add the following to Cargo.toml:
[dependencies]
atomic_ring_buffer = "1.0"
stdThe std feature enables use std::boxed::Box and std::vec::Vec for the backing storage.
This feature is enabled by default.
allocThe alloc feature enables use of alloc::boxed::Box for the backing storage.
This only works on nightly rustc.
collectionsThe collections feature enables use of collections::vec::Vec for the backing storage.
This only works on nightly rustc.
const_fnThe const_fn feature marks the AtomicRingBuffer::new function as constant, permitting
static initialization akin to:
static UART_BUFFER: AtomicRingBuffer = AtomicRingBuffer::new([u8; 32]);
This only works on nightly rustc.
atomic ring buffer is distributed under the terms of 0-clause BSD license.
See LICENSE-0BSD for details.