Skip to content

repro(glm53): publish qualified W4A4 DCP4 MTP5 source snapshot - #503

Closed
jackzampolin wants to merge 32 commits into
local-inference-lab:dev/jovian-judgementfrom
jackzampolin:repro/glm53-flash-nvfp4-w4a4-dcp4-mtp5-20260828
Closed

repro(glm53): publish qualified W4A4 DCP4 MTP5 source snapshot#503
jackzampolin wants to merge 32 commits into
local-inference-lab:dev/jovian-judgementfrom
jackzampolin:repro/glm53-flash-nvfp4-w4a4-dcp4-mtp5-20260828

Conversation

@jackzampolin

@jackzampolin jackzampolin commented Aug 28, 2026

Copy link
Copy Markdown

Purpose

Publish the exact vLLM source snapshot used by the qualified
ghcr.io/jackzampolin/glm53-flash-nvfp4-jovian community experimental image so
the runtime is reproducible and its branch/PR composition is explicit.

This is a source/reproduction snapshot, not a request to merge this combined
diff as-is. The individual changes should continue upstream feature-by-feature.

Exact source and artifact

  • source branch: jackzampolin:repro/glm53-flash-nvfp4-w4a4-dcp4-mtp5-20260828
  • source commit: 5c1702c572abad8672f66b6d5eab398583532ac5
  • source tree: 5177283cf2b757bb75bc65b824cc0766b2324ec3
  • recorded Jovian branch point: 3e63556c2b79de0b3a2f04648e575cb06e8ad276
  • qualified OCI index: sha256:6a89cd18c1dc38753d7eb9f18dbcb3e937c28a30675cee61f1a1d0dc662a4ecc
  • exact Linux/amd64 image manifest: sha256:6ebeaa39d468250e661a43e02201e7a01bc6aa420e3416aca5b47e545081d202
  • pinned parent image: sha256:60f6e0c3e8f7f299b6f73374cc51c43e61180f53ec6c924dbd1f1a1d0024decb
  • model revision: 520de24eabf507659eaef7c70f14fd584527facc

The prior image index sha256:eb9f5b9b... is superseded: its labels named this
commit, but its embedded source omitted the final CUDA-graph profiling
implementation and test. The replacement above was rebuilt directly from this
PR fetch ref and requalified.

PR composition

Included:

Not included:

The remaining commits after the PR-derived work are the tested production
harvest: caller-owned KDA scratch, parallel C4 prefill, mHC dispatch, stable KDA
backend selection, CUDA-graph resource retention/accounting, disabled-capture
profiling policy, bounded CKV workspace, and pre-KV-profiling B12X scratch.

Qualified runtime profile

4x RTX PRO 6000 Blackwell at stock clocks; NVFP4 W4A4 target experts through
Humming; TP4/DCP4; FP8 KV; MTP5 with Humming MXFP8; prefix caching/CKV; B12X
attention and linear; full decode plus piecewise prefill CUDA graphs; 524288
model length; 32 sequences; 4096 batched tokens; 0.88 GPU memory utilization.

Clean-rebuild validation:

  • five Estonia c30/high runs: 29, 28, 29, 29, 30; 145/150 pass (96.7%), zero
    runtime errors and zero max-token truncations
  • boot: 10,835,285 usable KV tokens and 9.62 GiB graph pool
  • matched prefill at 8K/64K/128K: -1.1%, +1.2%, -0.3% versus prior runtime
  • sustained C8: +5.4%/+6.1% at zero/8K context
  • sustained C32: +0.3%/-0.3% at zero/8K context
  • burst: 410/410 completed, zero errors

Full build/run instructions, component locks, commands, and result tables:
https://github.com/jackzampolin/glm53-flash-nvfp4-jovian

AI assistance disclosure: Codex assembled, tested, and documented this
integration snapshot. Human review remains required for individual upstream
changes.

jackzampolin and others added 30 commits August 28, 2026 00:57
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-Authored-By: Claude opus <noreply@anthropic.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-Authored-By: Claude Opus 4.1 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.1 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.1 <noreply@anthropic.com>
Co-Authored-By: Claude GPT-5.6 Sol <noreply@anthropic.com>
Co-Authored-By: Claude GPT-5.6 Sol <noreply@anthropic.com>
Co-authored-by: Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
Co-authored-by: OpenAI Codex <codex@openai.com>
(cherry picked from commit f538b46)
Add an opt-in piecewise-only graph mode for autoregressive draft prefill while retaining full CUDA graphs for target and draft decode.

Co-authored-by: OpenAI Codex <codex@openai.com>
(cherry picked from commit 0f335be)
GLM KDA decode retains the shape plan and creates a fresh B12X binding for each call from vLLM workspace scratch. This prevents a binding from outliving recyclable scratch or KV-cache state while leaving non-B12X and prefill paths unchanged.

Validation: tests/models/test_glm5next_model.py (26 passed); ruff check and format check.

Assisted-by: OpenAI Codex <codex@openai.com>

Signed-off-by: Martin Vit <martin@voipmonitor.org>
(cherry picked from commit 3328207)
Assign each completed C4 pool to an independent Triton program and update each request tail separately. Decode and speculative-decode requests retain ordered row processing, while prefill requires packed main-cache slots and consecutive positions.

Validated with GLM-5.3-Flash-NVFP4 on four RTX PRO 6000 Blackwell GPUs using a 32k-token standalone-prefill benchmark and parity tests for boundary tails, state-slot isolation, and invalid dummy slots.

Signed-off-by: Martin Vit <martin@voipmonitor.org>
(cherry picked from commit 18dd85c)
Use B12X mHC for decode-sized rank-local batches, including CUDA graph padding, and TileLang mHC for larger prefill batches. The dispatch threshold derives from scheduler capacity, speculative depth, CUDA graph capacity, tensor parallelism, and sequence parallelism. Every mHC operation in a decoder layer uses the same selected backend.

Validated with GLM-5.3-Flash-NVFP4 in W4A4 mode on four RTX PRO 6000 Blackwell GPUs. A 32k-token standalone-prefill benchmark sustained 13,280 prompt tokens/s for 30 seconds; concurrency-one decode without speculative tokens sustained 117.2 tokens/s.

Signed-off-by: Martin Vit <martin@voipmonitor.org>
(cherry picked from commit 159ca47)
Use the packed Triton KDA path for plain GLM-5.3 decode and the B12X KDA path for speculative decode by default. Plain decode avoids B12X metadata staging and validation overhead, while speculative decode retains B12X checkpoint selection and rollback handling.

Expose glm53_kda_decode_backend=auto|b12x|triton through additional_config. The default auto mode preserves B12X initialization for speculative requests; explicit values remain available for qualification and diagnosis. Unknown values fail during model construction.

Validation: six targeted GLM model tests; Ruff check and format; direct BF16 kernel comparison against the B12X reference for batch 1 over 64 sequential steps and batch 16; TP4 W4A4 decode benchmarks on physical GPUs 4-7.

Signed-off-by: Martin Vit <martin@voipmonitor.org>
(cherry picked from commit 28ee5e2)
Select one KDA implementation for the lifetime of every recurrent cache. Auto mode uses Triton when speculative decoding is disabled and B12X when an MTP or DFlash configuration is present. Explicit b12x and triton selections remain unchanged.

Both implementations satisfy the BF16 operation reference, but switching their rounding behavior between plain and speculative steps changes subsequent draft acceptance. A server-level choice preserves stable recurrent-state behavior and retains the qualified speculative rollback path.

Compatibility: the additional_config interface remains glm53_kda_decode_backend=auto|b12x|triton. Validation: nine targeted GLM model tests, Ruff check and format, and git diff validation.

Signed-off-by: Martin Vit <martin@voipmonitor.org>
(cherry picked from commit a4b04ee)
Keep Python owners registered during FULL CUDA graph capture alive for the lifetime of each captured graph. B12X mHC bindings own scratch and output tensors whose device pointers are embedded in a graph; releasing those bindings lets the allocator reuse their storage before replay.

Profiling teardown releases retained owners together with the graphs. Execution outside CUDA graph capture is unchanged.

Validated with the workspace resource tests, the B12X mHC binding test, and GLM-5.3-Flash NVFP4 TP4 target-plus-DFlash2 FULL graph replay on GPUs 4-7.

Signed-off-by: Martin Vit <martin@voipmonitor.org>
(cherry picked from commit 479f2ee)
Co-authored-by: OpenAI Codex <codex@openai.com>

Signed-off-by: Jack Zampolin <jack.zampolin@gmail.com>
Co-authored-by: OpenAI Codex <noreply@openai.com>
…inference-lab#457)

Preserve an explicitly configured Mamba state checkpoint cadence independently of the physical attention page size. Derive scheduler alignment from the resolved Mamba cache specifications and convert the annotated EAGLE draft boundary onto the recurrent-state grid. This keeps reusable recurrent and target-attention prefixes aligned when prefill chunks are smaller than the recurrent checkpoint interval.
Co-Authored-By: OpenAI Codex <noreply@openai.com>
jackzampolin and others added 2 commits August 28, 2026 10:54
Allow synchronous CKV gathering to borrow the persistent workspace when a draft attention layer has no resolved layer index. This keeps MTP graph warmup from falling back to a cache-capacity-sized transient allocation.

Co-Authored-By: OpenAI Codex <noreply@openai.com>
@coderabbitai

coderabbitai Bot commented Aug 28, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants