---
id: pr-flashinfer-2700
repo: flashinfer-ai/flashinfer
pr: 2700
title: Add varlen and speculative decoding support to selective state update
author: roikoren755
date: '2026-03-21'
url: https://github.com/flashinfer-ai/flashinfer/pull/2700
source_category: upstream-code
architectures:
- sm100
tags:
- gemm
techniques: []
hardware_features: []
kernel_types: []
languages:
- cuda-cpp
- triton
captured_at: '2026-04-27'
status: merged
merge_sha: 6fef5701a33c3a91c799e579232c79516ad789fc
inclusion_reason: kernel file changes
changed_paths:
- .gitignore
- benchmarks/routines/mamba.py
- csrc/flashinfer_mamba_binding.cu
- csrc/selective_state_update.cu
- csrc/selective_state_update_customize_config.jinja
- flashinfer/aot.py
- flashinfer/jit/mamba/selective_state_update.py
- flashinfer/mamba/selective_state_update.py
- include/flashinfer/mamba/kernel_selective_state_update_mtp.cuh
- include/flashinfer/mamba/kernel_selective_state_update_stp.cuh
- include/flashinfer/mamba/selective_state_update.cuh
- tests/mamba/test_selective_state_update_varlen.py
- tests/mamba/triton_reference/selective_state_update_varlen.py
head_ref_oid: b6e179beaea9d45645af0dfd997f9504c41d3537
artifact_dir: evidence/pull-bundles/flashinfer/gh-2700
---
# Add varlen and speculative decoding support to selective state update

- Repository: `flashinfer-ai/flashinfer`
- PR: [2700](https://github.com/flashinfer-ai/flashinfer/pull/2700)
- Decision: `kernel file changes`
- Reason: kernel file changes

## Changed Paths

- `.gitignore`
- `benchmarks/routines/mamba.py`
- `csrc/flashinfer_mamba_binding.cu`
- `csrc/selective_state_update.cu`
- `csrc/selective_state_update_customize_config.jinja`
- `flashinfer/aot.py`
- `flashinfer/jit/mamba/selective_state_update.py`
- `flashinfer/mamba/selective_state_update.py`
- `include/flashinfer/mamba/kernel_selective_state_update_mtp.cuh`
- `include/flashinfer/mamba/kernel_selective_state_update_stp.cuh`
- `include/flashinfer/mamba/selective_state_update.cuh`
- `tests/mamba/test_selective_state_update_varlen.py`
- `tests/mamba/triton_reference/selective_state_update_varlen.py`

## Evidence Bundle

`evidence/pull-bundles/flashinfer/gh-2700`
