Expand description
Intrusive concurrent collections backed by Crossbeam’s epoch collector.
Nodes implement SinglyLinked and, optionally, DoublyLinked. Links
point directly to complete nodes, so there are no adapters or link-to-node
conversions. The default std feature enables the sharded stack, sharded
ConcurrentShardedQueue.
Disabling it leaves the link traits and the alloc-enabled epoch API.
§Choosing a collection
ConcurrentShardedQueue: per-shard FIFO with local enqueue and XOR probing.ConcurrentShardedStack: per-shard LIFO with local push and XOR probing.
Collections take ownership through Box<T> and return results from
shared-borrow callbacks. They do not return removed nodes for immediate reuse.
Queue shards retain their last consumed node as a dummy until the next pop
or destruction. See each collection for ordering and reclamation semantics.
Rust 1.85 or newer and pointer-width atomic operations are required.
Re-exports§
pub use crossbeam_epoch as epoch;
Structs§
- Atomic
Link - An atomic forward/backward link stored privately in an intrusive node.
- Concurrent
Sharded Queue - An intrusive MPMC queue distributed across independent FIFO shards.
- Concurrent
Sharded Stack - An intrusive Treiber stack distributed across cache-padded shards.
Enums§
- PopError
- The result of an operation that did not find a node.
- Push
Error - A rejected push, retaining ownership of the unpublished node.
Traits§
- Doubly
Linked - A node that also contains an atomic backward link.
- Singly
Linked - A node containing an atomic forward link to another complete node.