mirror of
https://github.com/deepseek-ai/DeepGEMM.git
synced 2026-11-05 00:47:26 +00:00
[GH-ISSUE #317] DeepSeek-V4 on SM120: tf32_hc_prenorm_gemm and paged_mqa_logits kernels missing #159
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
deepseek-ai/DeepGEMM#159
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @rs-ipps on GitHub (Apr 24, 2026).
Original GitHub issue: https://github.com/deepseek-ai/DeepGEMM/issues/317
Summary
Two DeepGEMM kernel families used by DeepSeek-V4 hit
Unsupported architectureassertions on SM120 (Compute Capability 12.0):tf32_hc_prenorm_gemm— used by Manifold-Constrained Hyper-Connections (mHC). Assertion atcsrc/apis/hyperconnection.hpp:56.get_paged_mqa_logits_metadata/paged_mqa_logits— used by the Lightning Indexer. Assertion atcsrc/apis/attention.hpp:211.This blocks DeepSeek-V4-Flash and DeepSeek-V4-Pro from running on RTX Pro 6000 Blackwell and RTX 5090 GPUs in frameworks that depend on DeepGEMM for these kernels.
Looking at
csrc/apis/hyperconnection.hppand theimpls/directory, onlysm90_tf32_hc_prenorm_gemm.hppandsm100_tf32_hc_prenorm_gemm.hppexist — there is no SM120 implementation. The same pattern applies to the paged MQA logits kernels (see existing Issue #236, which reports the missingsm120_fp8_paged_mqa_logits.cuh).Environment
cu130)deepseek-ai/DeepSeek-V4-Flash(released 2026-04-24)Two frameworks were tested:
0.1.dev15830+g8d599d76a(imagevllm/vllm-openai:deepseekv4-cu130)lmsysorg/sglang:deepseek-v4-blackwell, container CUDA 12.9.1)Crash 1: HyperConnection kernel (vLLM)
Launching DeepSeek-V4-Flash with
tensor-parallel-size 2,--kv-cache-dtype fp8,--enforce-eager. The model loads successfully (148.66 GiB across 46 shards, ~73.91 GiB per GPU). The crash occurs duringprofile_run, on the first forward pass through an HC layer.Crash 2: Lightning Indexer kernel (SGLang)
With
SGLANG_DISABLE_DEEP_GEMM=1,--fp8-gemm-backend triton,--moe-runner-backend triton, and--disable-cuda-graph, SGLang successfully:DSv4 compressed attention: kv_cache_dtype=torch.float8_e4m3fn)Prefill batch, #new-seq: 1, #new-token: 256)On the first forward pass, the crash occurs inside the attention backend's indexer metadata initialization:
Notably, SGLang's mHC path does not crash on SM120 — SGLang implements
mhc_previa TileLang (TVM-based JIT), visible in the stack trace atsglang/srt/layers/mhc.py:514callingtilelang/jit/kernel.py. TileLang generates SM120-compatible code at runtime. This demonstrates that at least for the HC kernel, an SM120-capable alternative implementation path exists.SGLang's Lightning Indexer path, however, calls
get_paged_mqa_logits_metadatadirectly from DeepGEMM with no alternative backend, so theattention.hpp:211assertion is a hard blocker.Root cause
Both assertions dispatch by compute capability and find only
sm90_*andsm100_*implementations.csrc/jit_kernels/impls/contains no SM120 variants for either kernel family.This extends the SM120 gap already tracked in:
tcgen05.fencenot available on SM120) or SM90 kernels (wgmmanot available on SM120); SM120 needs its own implementations.sm120_fp8_paged_mqa_logits.cuh.Impact
DeepSeek-V4 (both Flash and Pro) cannot complete a forward pass on any consumer/workstation Blackwell GPU (RTX 5090, RTX Pro 6000 Blackwell) in vLLM or SGLang until SM120 implementations of these kernels exist. V4-Flash fits on 2× RTX Pro 6000 from a memory perspective (~88 GiB per GPU for weights, within the 96 GiB per-GPU budget), so this is purely a kernel-availability issue.
Request
Would the team consider adding SM120 implementations for:
tf32_hc_prenorm_gemm(and any related HC-API kernels)paged_mqa_logitsandget_paged_mqa_logits_metadataEven slower reference implementations that simply unblock SM120 would be highly valuable to the community while tuned versions are developed.
If the team is unable to prioritize this, would a community contribution be welcome? Guidance on the expected approach (e.g., CUTLASS 4.x SM120 collective builder, hand-written kernels, or exposing a non-DeepGEMM fallback through the same API) would help others contribute.
Thank you for your work on DeepGEMM.
@zheanxu commented on GitHub (Apr 30, 2026):
Thanks for the detailed report. Please see PR #318 for a reference implementation. We do not plan to maintain SM120 ourselves due to lack of hardware and manpower, but community contributions are very welcome.