pub struct RingAtomics {
pub head: AtomicU64,
pub tail: AtomicU64,
pub ready: Vec<AtomicU64>,
pub done: Vec<AtomicU32>,
}Expand description
Shared atomics between host producers and device consumers.
Fields§
§head: AtomicU64Monotonically increasing next-slot-to-claim by a producer.
tail: AtomicU64Monotonically increasing next-slot-to-claim by a consumer.
ready: Vec<AtomicU64>Per-slot publication sequence. A producer writes the slot payload first
and then publishes head + 1 here with Release; consumers wait for
that exact sequence before reading the packed payload.
done: Vec<AtomicU32>Per-slot completion marker (1 = done).
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for RingAtomics
impl RefUnwindSafe for RingAtomics
impl Send for RingAtomics
impl Sync for RingAtomics
impl Unpin for RingAtomics
impl UnsafeUnpin for RingAtomics
impl UnwindSafe for RingAtomics
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more