Skip to main content

CuPayloadSize

Trait CuPayloadSize 

Source
pub trait CuPayloadSize {
    // Provided methods
    fn raw_bytes(&self) -> usize { ... }
    fn handle_bytes(&self) -> usize { ... }
}
Expand description

Lightweight trait to estimate the amount of data a payload will contribute when serialized. Default implementations return the stack size; specific types override to report dynamic data.

Provided Methods§

Source

fn raw_bytes(&self) -> usize

Total bytes represented by the payload in memory (stack + heap backing).

Source

fn handle_bytes(&self) -> usize

Bytes that correspond to reusable/pooled handles (used for IO budgeting).

Implementors§

Source§

impl<T> CuPayloadSize for CuHandle<T>
where T: ArrayLike,

Source§

impl<T> CuPayloadSize for T
where T: CuMsgPayload,