Frozen-bank fused-MoE forward returns corrupted bytes after unrelated GPU tests run (sglang fused-MoE combine-stage state bug)
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 30/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- python
- Ambito
- machine-learning, testing-qa
Direzione di ricerca
Run the three named tests in one process and compare the frozen-bank byte test with a clean run. Trace Glm52NativeBlockFP8Experts through _sglang_ep_native_routed_value, fused_experts_impl_strided, the vendored fused_moe.py orchestration, and the sgl_kernel combine/epilogue path; done means the final tensor remains correct and deterministic after the two polluter tests.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Symptom
tests/models/test_glm52_fullparam_frozen_trunk_backward.py::test_cuda_frozen_bank_value_bytes_identical_with_and_without_grad_engagement fails in the GPU models CI shard (first surfaced on #82, which made sglang importable in the trainer env so this sglang-gated test runs in CI at all). It passes standalone and within its own file.
Minimal reproducer (H100, torch 2.11.0, sgl-kernel 0.4.5, triton 3.6.0)
Run in one process, in this order:
tests/models/test_batch_invariance_dense.py::test_dense_batch_composition_invariance_policytests/models/test_glm52_exact_routed_experts_qlora.py::test_routed_experts_literal_sampler_and_gradient_policy- the frozen-bank byte test
After steps 1–2, Glm52NativeBlockFP8Experts forward (_sglang_ep_native_routed_value → fused_experts_impl_strided → sglang fused_experts_impl, topk=1, EP-native local_ids with one -1 sentinel, routed_scaling_factor=1.5) returns structurally wrong and run-to-run nondeterministic outputs for bit-identical inputs: clean row norms [0.268, 0.536, 0.144, 0.287, 0.107] become [0.0, 0.0, 0.761, 0.761, 0.025] (± garbage up to 1e37 in some runs).
Evidence trail (all verified on H100)
Instrumented every Python-visible stage boundary, clean vs polluted process, identical fixture inputs:
moe_align_block_size: inputs identical;sorted_ids/num_tokens_post_paddedidentical;expert_idsdiffers only in its uninitialized tail slot (block 5 of 5, beyond post-pad;torch.emptyresidue:0x08080808fresh page vs0x3F800000freed-float) — forcing that slot to-1does not fix the failure.- GEMM1 (
invoke_fused_moe_kernel): input and output row norms bit-identical. - Activation:
intermediate_cache2differs only in the filtered row (uninitialized by design). - GEMM2: output (
intermediate_cache3) row norms bit-identical. - Final returned tensor: differs. The divergence enters between the last kernel invoke and the returned tensor (combine stage).
Ruled out empirically: torch backend flags (tf32/reduced-precision/deterministic — unchanged), xorl batch-invariant mode leak (off), bi_families_v2 selection (None), sglang exec-context (deterministic inference enabled in both), triton in-process JIT caches (cleared, no change), _down_moe_use_tma (forced off, no change), CUDA allocator state (empty_cache(), no change; NaN-priming a clean process does not reproduce), sgl_kernel.moe_sum_reduce primitive on fixed input (identical clean vs polluted).
Where this points
Persistent library state inside the pinned sglang fused-MoE stack's combine/epilogue path (sgl_kernel 0.4.5 + the vendored fused_moe.py orchestration), toggled by whatever the two polluter tests initialize. Needs debugging at the compiled-kernel level in xorl-sglang.
Interim state
The test is quarantined with xfail(strict=False) referencing this issue (PR #82). The frozen-bank byte contract itself holds when the process history is clean — verified 20/20 deterministic standalone runs.
- Lingua principale
- Python
- Stelle
- 52
- Fork
- 2
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di togethercomputer/xorl
-
sync_inference_weights corrupts the sampler for dense Qwen3 models with tied embeddingsForse già presa @qywu l’ha presa 102 giorni fa. Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
togethercomputer/xorl#87 · 2 commenti ·
-
Value-model (critic) support for the tinker-compat API via multi-LoRA (SAO, arXiv:2607.07508)Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 18/100
togethercomputer/xorl#84 · 4 commenti ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
togethercomputer/xorl#79 · 5 commenti ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
togethercomputer/xorl#78 · 2 commenti ·
-
Consolidate the exact and generic scoring paths; implement top-k/top-p/min-p on the generic pathAperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 32/100
togethercomputer/xorl#71 · 1 commento ·
Tutte le issue di togethercomputer/xorl
Issue simili
-
soup prune-prompt exits 1 after writing its output on a file over 100,000 rows, and reports a capped row count otherwiseForse già presa @abdulwaarith0 l’ha presa oggi. Apertaneeds-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
MakazhanAlpamys/Soup#3690 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
bug data-types native-format
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
ClickHouse/clickhouse-connect#1320 ·
I maintainer di solito rispondono entro 1 giorno
-
Public benchmark import end-to-end test fails when the test stack's worker runs the parity jobApertaaccepted
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
future-agi/future-agi#6392 ·
I maintainer di solito rispondono entro 1 giorno