Conversation
This was referenced Sep 10, 2026
Fridge003
force-pushed
the
codex/glm53-ingraph-verify-metadata
branch
from
September 10, 2026 19:59
65ec643 to
879fdc8
Compare
Fridge003
force-pushed
the
codex/glm53-kpool-metadata-fusion
branch
from
September 10, 2026 19:59
b327ef9 to
e586d07
Compare
Co-authored-by: Xinyuan Tong <xinyuantong.cs@gmail.com> Co-authored-by: zRzRzRzRzRzRzR <Yuxuan.Zhang2@liverpool.ac.uk> Co-authored-by: Shijin Zhang <75300765+Dovis01@users.noreply.github.com> Co-authored-by: zanes-ops <zanes@nvidia.com>
Fridge003
force-pushed
the
codex/glm53-ingraph-verify-metadata
branch
from
September 12, 2026 23:05
879fdc8 to
3b8b482
Compare
Collaborator
Author
|
This optimization is not valid |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Restore
SGLANG_EXPERIMENTAL_DSA_INGRAPH_VERIFY_METADATA=1, removed by #38071. With KPool fusion enabled, target verification can refresh its metadata inside the model CUDA graph instead of launching that sequence eagerly before each replay.Builds on PR #38845, now merged into
main. KPool metadata fusion is enabled by default for supported CUDA geometry; this PR adds the separate, default-off in-graph verify flag.The follow-up DeepGEMM option is PR #38858. This PR is rebased onto
mainata66451c058dcce0799f5c6d1620b527371db4828and targetsmain; its diff contains only the in-graph optimization.Modifications
dsa_metadata_ingraph.pymixin; the backend contains only initialization and lifecycle hooks.plan_topk_v2, with shape/dtype/device/layout validation.Accuracy Tests
Rebased head:
3b8b48279969253e2d0fad43109328b94e766f6d. The rebase preserves main's consolidatedDSAMetadataManagementMixinand default-on KPool fusion, while retaining the default-off in-graph flag. Changed-file pre-commit checks andgit diff --checkpass. The B200 correctness and benchmark results below are the preserved pre-rebase measurements; GPU tests were not rerun for this rebase.Draft: the unchanged full-model accuracy gate did not pass. On
baizhou-dev-b200(4× B200), commit65ec643b4707d13200edd7474445cf60fa2f1271with both restoration flags enabled:SGLANG_EXPERIMENTAL_DSA_KPOOL_METADATA_FUSION=1 \ SGLANG_EXPERIMENTAL_DSA_INGRAPH_VERIFY_METADATA=1 PYTHONPATH=python \ python test/registered/e2e/models/test_glm53_flash_b200.py -v # Ran 4 tests in 687.185 s: FAILED (errors=1)The test file, 500 GSM8K examples, 20 shots and 0.930 floor are unchanged. The test wrapper reports the failing accuracy assertion as an error.
The LowLatency speed/acceptance test passes: 353.51 tok/s, 4.605 accept length (gates: >250 tok/s and >4.0). The in-graph verify path is active in the real model logs.
Focused in-graph GPU regressions pass 4/4:
Unmodified main also failed the LowLatency accuracy floor: 0.928 initially and 0.920 in one controlled repeat. The parent KPool PR passed its full run (LowLatency 0.936). Baseline variability does not establish that this change is harmless. All original results and thresholds are retained. One controlled repeat of the unchanged LowLatency class passed 2/2 in 290.203 s: GSM8K 0.936, speed 350.79 tok/s, accept length 4.422. Run the same command above with
TestGLM53FlashB200LowLatencyappended to select that class. The initial 0.926 failure remains part of the evidence. This PR stays draft because the intermittent full-model accuracy failure remains unexplained; a passing repeat does not resolve its cause.An additional real-GPU metadata diagnostic passed 16 configurations × 17 rounds = 272 graph replays: bs=1/4/16/48, draft lengths 2/4/6/8, changing sequence lengths across pool/page/top-k boundaries through 100001 tokens, and remapped requests. It interleaves live graphs and compares ordinary versus optimized metadata and stable destination addresses. This isolates metadata construction; it is not a substitute for the full-model accuracy gate. The script, exact heads/flags and logs are in the evidence link below.
Speed Tests and Profiling
Same four B200 GPUs on
baizhou-dev-b200, TP4/EP4, CUDA 13.0, driver 580.173.02, PyTorch 2.13.0+cu130, Triton 3.7.1, DeepGEMM 0.1.7 and FlashInfer 0.6.18. The fixed main baseline is9a2f17f41d185614a17f740c006c4aca84c016bf.Model revisions:
zai-org/GLM-5.3-Flash@eb9eb208eb0d988989d07a6a12d0fdeb5f52574aandincoai/GLM-5.3-Flash-DFlash2@bf582e4eacc1810f76656d1811693ff6c6737d2a. Every weight shard was SHA256-verified.Serving benchmarks use the test file's LowLatency EAGLE recipe, with radix caching disabled consistently for measurement.
bsmeans--max-concurrency; each run sends4 * bsrequests under that concurrency limit. Inputs are exactly 8192 token IDs, outputs exactly 1024 tokens, seed 42, temperature 0, one warmup request and a cache flush. EOS is ignored by the current CLI default. Each cell has three runs; throughput is the median of the three run-level rates, and latency is the median of the three run means; throughput ranges are retained. All measured requests completed with the expected token counts.This workload shows no incremental throughput gain over the parent PR: the measured median throughput is lower by 2.5%, 0.8% and 0.9% at bs=1/4/16. The cumulative results remain above the fixed main baseline.
Latency medians for this PR:
Reproduce from this PR's checkout (other restored flags unset):
In another shell after the server is ready:
Raw run-level measurements, accuracy records and a standalone recomputation script are available together.
Checklist
base-b-kernel-unit.CI States
Latest PR Test (Base): ❌ Run #34724482723
Latest PR Test (Extra): ❌ Run #34724482748
Latest PR Test (AMD ROCm 10): ❌ Run #34724482716