pub struct DeviceLayerCache {
pub kda: Option<KdaDeviceState>,
pub mla_k: Option<DevicePtr>,
pub mla_v: Option<DevicePtr>,
pub seq_len: usize,
pub cap: usize,
}Expand description
One layer’s device buffers. MLA k/v are pre-allocated to cap tokens
so append is a strided H2D of the new row only.
Fields§
§kda: Option<KdaDeviceState>§mla_k: Option<DevicePtr>§mla_v: Option<DevicePtr>§seq_len: usize§cap: usizeAuto Trait Implementations§
impl Freeze for DeviceLayerCache
impl RefUnwindSafe for DeviceLayerCache
impl Send for DeviceLayerCache
impl Sync for DeviceLayerCache
impl Unpin for DeviceLayerCache
impl UnwindSafe for DeviceLayerCache
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