Repository navigation
Conversation
Preserve negative padding indices through FlashInfer indexed decode so padded CUDA Graph lanes cannot overwrite the last live GDN state slot. Provide explicit, hash-guarded application for validated SGLang sources and require a separately provisioned FlashInfer >= 0.6.18 runtime. Refs: sgl-project/sglang#44014 Signed-off-by: yulangz <53958801+yulangz@users.noreply.github.com>
yulangz
requested review from
Le8r0nJames,
garrett4wade,
geshi001 and
sitabulaixizawaluduo
as code owners
October 19, 2026 07:14
Contributor
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
Le8r0nJames
approved these changes
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.
Description
Backport sgl-project/sglang#44014
as an explicit AReaL source patch for SM90 FlashInfer GDN decode.
With padded decode CUDA Graphs,
cache_indicescontains-1. The SM90Python gather/scatter path treats it as the last real state-pool slot.
Padded lanes can therefore overwrite live or cached recurrent state,
causing intermittent corrupted output in subsequent generation.
The backport passes the full pool and int32 indices to FlashInfer's indexed
decode API. It preserves the SM100+ branch, prefill and MTP code. It uses
AReaL's existing atomic, locked source-patch installer, validates input/output
hashes, refuses unknown sources, and is idempotent.
Apply before starting servers, in the SGLang interpreter:
A disposable source copy can be checked without local GPU dependencies:
Runtime boundary: installed application requires a separately provisioned
FlashInfer >= 0.6.18 runtime. AReaL currently pins SGLang 0.5.10.post1 with
FlashInfer 0.6.7.post3; that older FlashInfer is rejected before any write.
This PR does not change dependency pins or auto-enable the patch. Source
hashes cover SGLang 0.5.10.post1, 0.5.20 and the original upstream PR base
module, with the same SM90 fix adapted to their different call sites.
Related Issue
Upstream fix: sgl-project/sglang#44014 (still open).
Type of Change
Validation
writes, permission preservation, unknown-source refusal and runtime guards.
0.6.18: 2 test methods per profile, covering BF16/FP32 states, int32/int64
indices, eager decode and CUDA Graph replay with changing index patterns.
Checks include untouched live slots, especially the last allocatable slot,
and valid-row state/output agreement with an unpadded reference.
pre-commit run --all-fileswas attempted. Its project-wide manifest/CLIhooks could not pass in the minimal Python 3.10 check environment:
tomllibandhttpxwere unavailable, anduvwas not on the hook PATH.Formatting, linting, license and other source checks passed. The GPU tests
used a separate Python 3.12 runtime. Full training/distributed integration
was not run for this standalone source backport.
Checklist
Prepared with coding-agent assistance; public code and synthetic regression
inputs only.