pub struct DflashKv {
pub k: Vec<CudaSlice<f32>>,
pub v: Vec<CudaSlice<f32>>,
pub len: usize,
pub cap: usize,
}Expand description
Draft KV cache (round-cost fix, 2026-07-13): per-layer normed+roped ctx K and raw ctx V, append-only in committed order. Block K/V land TRANSIENTLY at [len..len+b] each round (never committed — the reference crops them identically). Kills the per-round full-ctx projection recompute (first light was O(ctx)/round -> 7 tok/s).
Fields§
§k: Vec<CudaSlice<f32>>§v: Vec<CudaSlice<f32>>§len: usize§cap: usizeImplementations§
Auto Trait Implementations§
impl Freeze for DflashKv
impl RefUnwindSafe for DflashKv
impl Send for DflashKv
impl Sync for DflashKv
impl Unpin for DflashKv
impl UnsafeUnpin for DflashKv
impl UnwindSafe for DflashKv
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