pub fn reshape_and_cache_nvfp4(
gpu: &dyn GpuBackend,
kernel: KernelHandle,
key: DevicePtr,
value: DevicePtr,
k_cache: DevicePtr,
v_cache: DevicePtr,
slot_mapping: DevicePtr,
num_tokens: u32,
num_kv_heads: u32,
head_dim: u32,
block_size: u32,
key_stride: u32,
value_stride: u32,
block_stride_bytes: u64,
data_section_bytes: u64,
stream: u64,
) -> Result<()>Expand description
2026-09-25: Write each token’s K and V into the paged NVFP4 cache at its
slot_mapping slot: E2M1 values with one E4M3 scale per 16. One block per
token.