Repository navigation
Conversation
Merge the NVFP4 training slice and add request-wide amax scratch to the engine-owned cache. Reuse upstream two-pass NVFP4 quantization at handoff and flush, including captured decode execution. Validation: runtime and test hashes match JHB GB300 job 1118220, with 12 GPU tests and the NVFP4 full-decode CUDA-graph engine test passing. Focused CPU tests and pre-commit passed; no full-model NVFP4 accuracy claim. Signed-off-by: Kai Xu <kaix@nvidia.com>
Share an upstream-codec read refresh between training and the vLLM cache. Keep the FP32 anchor and nearest-rounded E4M3 scales unchanged, and retain sampled reads for the identity-STE backward. Use per-request device RNG seeds for graph-safe cache refresh and reset. Signed-off-by: Kai Xu <kaix@nvidia.com>
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
Contributor
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
Comment |
kaix-nv
added this pull request to stack #2879
October 19, 2026 22:19
This was referenced Oct 19, 2026
This branch has not been deployed
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.
Linear-attention series — 10 PRs
mainThe nine open PRs form native GitHub stack #2879 in this order. #2497 has landed, so #2519 targets
main.#2829 supplies the shared rounding policy before ReplaySSM training and serving. #2788 owns the ReplaySSM training foundation; #2541 owns ordinary state-QDQ serving; #2878 adds the experimental two-precision ReplaySSM serving backend and native stochastic NVFP4 read integration. The serving branch inherits rounding from #2829 without a temporary backport.
#2503 and #2507 retain their existing code and commit heads. Their functional ports and rebases remain deferred until their immediate parents land; their bases and table positions express the intended merge order. Serving-time prefill-GEMM QDQ remains deferred until an optimized fused kernel is available.
What does this PR do?
Type of change: New feature.
Add an opt-in vLLM worker for two-precision GDN ReplaySSM state quantization. It installs the recipe before cache allocation so vLLM owns the FP32 recurrence anchor, FP8/NVFP4 read checkpoint and 16-token replay buffers. Chunked prompt prefill, decode cache refresh, request-slot reuse and decode CUDA graphs share the same cache policy as training.
NVFP4 read checkpoints optionally use
gdn_read_quantizer.rounding="stochastic", supplied by #2829. E4M3 block scales retain nearest rounding and the recurrence anchor stays FP32. Training saves the sampled reads for its identity-STE backward; serving uses per-request device RNG seeds that work with CUDA graphs. The temporary rounding backport has been removed; the API comes from the parent stack.This is a new backend with a coupled worker, cache layout and refresh kernel. The worker and cache must land together to have a runnable intermediate state. It reuses the optional upstream ReplaySSM emulation kernels rather than copying their implementation. This is floating-storage numerical emulation, not packed-cache compression.
Usage
Install the optional ReplaySSM dependency pinned in
examples/llm_qat/linear_attention/REPLAYSSM.md, alongside vLLM 0.30.x. Use an exported Hugging Face checkpoint and the same explicit recipe as training:The example README includes the complete CUDA-graph launch configuration and the YAML override for stochastic NVFP4 reads. Supports GDN with K=128, one GPU and one active request; speculative decoding and cache transfer are unsupported. Standard inference export still rejects stochastic quantizers: this worker installs the supported policy from its explicit recipe.
Testing
git diff --checkpassed.db9053881fsource byte-for-byte.Before your PR is "Ready for review"