Repository navigation
Conversation
This was referenced Sep 8, 2026
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.
Superseded by XingLiu1/sglang#6. The change is now a review PR targeting
agent/flexkv-dsv4-main, the branch behind upstream #31781. The mistaken direct push to that branch was reverted; prefetch is not yet incorporated. The review head2f91f9f5f0has the same source tree as the version that passed 167 CPU tests and 12 subtests. Companion: FlexKV #291.Motivation
FlexKV's whole-prefix prefetch cannot stop issuing remote work when a queued request becomes a scheduling candidate or exhausts its prefetch budget. Integrate the optional chunked API from taco-project/FlexKV#291 so SGLang can consume a safely drained partial prefix and compute the remainder.
Modifications
Depends on the companion FlexKV PR. Rebased on SGLang
5aab054ec8; the default remains unchanged unless FlexKV chunked prefetch is enabled. Configuration, interfaces, sequence diagrams and monitoring boundaries are documented in the companion PR'sdocs/design/chunked_prefetch_reference.mdand review document.chunk_max_blocksis the single chunk-size option; remove the former experimentalchunk_target_bytesfield.Accuracy Tests
Earlier implementation snapshots passed 25 real H20/Mooncake tests, a Full+SWA byte round trip, and 210/210 formal requests each for GLM-5.2 and V4 Flash (TP8/DP1). Full generated-token comparisons were used. Those results predate this rebase and chunk-size simplification; repeat GPU/model checks on the paired PR revisions before marking ready.
Speed Tests and Profiling
No throughput or latency improvement is claimed. Earlier C1/C8/C32 workloads included shared prefixes, queueing and CPU/GPU cache hits. Same-cache-state repeated A/B, IPC/forward timeline alignment, longer load/fault/resource checks, and DP/layerwise coverage remain outstanding. Dedicated chunked-prefetch Prometheus instrumentation is follow-up work and is explicitly separated from existing metrics in the design.
Checklist
CI States
Latest PR Test (Base): ❌ Run #34200927062
Latest PR Test (Extra): ❌ Run #34200926458
Latest PR Test (AMD ROCm 7.2): ❌ Run #34200926774