DeepSeek-V4-Flash-Vision-Exp TP2/TP4: b12x tiny-decode MoE kernel skips `swiglu_limit` (fix in local-inference-lab/flashinfer#83)
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 38/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- rust
- Área
- performance
Línea de trabajo
The issue identifies the affected FlashInfer tiny-decode kernel and the proposed fix in local-inference-lab/flashinfer#83. Read that pull request and inspect the kernel path for 1–4 token MoE launches, then check the reported TP2 and TP4 shard shapes and GPU test. Done means the tiny kernel applies swiglu_limit and calls without a limit retain current behavior.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Summary
For MoE launches of 1-4 tokens, b12x's W4A8-MX path can select the tiny-decode kernel. That kernel computes plain SiLU-GLU and never applies swiglu_limit. The deepseek4 recipe's checkpoint (DeepSeek-V4-Flash-Vision-Exp-lossless-CSF) sets swiglu_limit = 10.0, and its TP2 and TP4 expert shards are tiny-decode eligible. So 1-4 token decode steps (one to four active sequences, small verification rounds, draft MoE) run the routed experts without the clamp whenever a gate/up activation exceeds 10.
The fix is open as local-inference-lab/flashinfer#83: the tiny kernel applies the clamp, and calls without a limit compile to today's code.
Affected (Hyperflare main, FlashInfer pin local-inference-lab/flashinfer@e0f105b3)
| Model (recipe) | TP | Per-rank expert width (hidden) | 1-4 token kernel | Limit applied |
|---|---|---|---|---|
DeepSeek-V4-Flash-Vision-Exp (deepseek4) |
2 | 1024 (4096) | tiny | no |
| 4 | 512 (4096) | tiny | no | |
DeepSeek-V4.1-Flash (deepseek41) |
4 | 576 (5120) | compact micro | yes |
NVFP4 recipes (GLM-5.3-Flash, MiniMax-M3, Step5) don't reach this kernel.
Evidence (RTX PRO 6000 Blackwell, SM120)
-
Kernel level, at the DeepSeek-V4 TP2 and TP4 shard shapes (k4096/n1024 and k4096/n512, 256 experts, top-6, 1 and 4 tokens; the GPU test in #83):
- on
main, selection picks tiny and the launch doesn't receive the limit; - with inputs that exceed the limit, the output misses the clamped reference;
- with #83, it matches a tiny-arithmetic oracle (cos ≥ 0.9999, normalized RMSE ≤ 1%).
- on
-
End to end on the shipped config (Hyperflare main 8c2e782, DeepSeek-V4-Flash-Vision-Exp TP2 on 2x RTX PRO 6000,
--no-mtpso every decode step is a 1-row MoE launch; decode vs teacher-forced prefill; two separate exports per variant, 20 + 40 runs = 18,000 tokens each):FlashInfer Confidently wrong tokens (decode drop, prefill top-1 > 0.74) Sudden decode drops (top-1 < 0.2 after two confident tokens), prefill also unsure pin e0f105b3 (tiny kernel, no clamp) 0 327 (89 + 238), 1.8% of tokens pin + #83 clamp 0 63 (14 + 49), 0.35% of tokens On DS4 the missing clamp shows as ~5x more sudden low-confidence decode steps (6.4x and 4.9x in the two runs) rather than confidently wrong tokens.
-
End to end on DeepSeek-V4.1-Flash at TP3 (a downstream, non-shipped config, same tiny shape class): 10 of 20 runs emitted a token that teacher-forced prefill rejects with high confidence; with the clamp, 0 of 20. Replay of captured bad steps: routed MoE output 9-18x off unclamped, 0.4-0.5% from an exact float64 recomputation with the clamp.
Note: exporting deepseek4 on main currently fails before this point: ignition/components/weights.py lists an engram field for ignition.recipes.deepseek4.weights.LayerWeights, which has none ('LayerWeights' object has no attribute 'engram' in rebuild_manifest.declared_views). The measurement above dropped engram from that entry; nothing else was changed.
Workaround until #83 lands
B12X_W4A8_TINY_DECODE=0 keeps the tiny kernel off (+34% per MoE call at 1 token). Prepared packages and tuning made with tiny enabled must be re-prepared, because the switch isn't part of the tuning key. The deepseek4 recipe could also set it through b12x_environment.
- Lenguaje dominante
- Rust
- Estrellas
- 800
- Forks
- 106
- Merge medio
- 1 d 3 h
- PR fusionados (30 d)
- 100
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de NVIDIA/hyperflare-inference
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
NVIDIA/hyperflare-inference#268 ·
Los mantenedores suelen responder en 1 día
-
break out engram wait timeAbiertoarea:caching area:engram enhancement performance triage:design-review
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
NVIDIA/hyperflare-inference#230 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 15/100
NVIDIA/hyperflare-inference#278 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
NVIDIA/hyperflare-inference#276 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
NVIDIA/hyperflare-inference#271 ·
Los mantenedores suelen responder en 1 día
Todos los issues de NVIDIA/hyperflare-inference
Issues similares
-
bug UI
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
wardian-app/Wardian#1746 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
jlcodes99/cockpit-tools#3125 ·
Los mantenedores suelen responder en 2 días
-
bug user-sprint
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Vondor/KassenSturz#967 ·
Los mantenedores suelen responder en 1 día
-
area/ci
Dificultad 1/5 Menos de una hora Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
-
[BUG] Incremental sync warns "no stored highest_uid" on every round for folders with no new mailAbiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
rustmailer/bichon#411 ·