rope_strided

Function rope_strided 

Source
pub fn rope_strided(
    gpu: &dyn GpuBackend,
    kernel: KernelHandle,
    q: DevicePtr,
    k: DevicePtr,
    positions: DevicePtr,
    num_tokens: u32,
    num_q_heads: u32,
    num_kv_heads: u32,
    head_dim: u32,
    rotary_dim: u32,
    theta: f32,
    q_row_stride: u32,
    k_row_stride: u32,
    stream: u64,
) -> Result<()>
Expand description

2026-09-25: rope for rows that are not packed: Q rows q_row_stride and K rows k_row_stride elements apart, all num_tokens rows in one launch. rope_forward_strided differs from rope_forward only in the row address, so the packed strides give the same result as rope.