Repository navigation
[PD] Use one logical-range contract for DSA state indices - #37770
Closed
IvanShan177 wants to merge 1 commit into
Closed
IvanShan177 wants to merge 1 commit into
IvanShan177 wants to merge 1 commit into
Conversation
9 of 18 tasks
IvanShan177
force-pushed
the
fix/pd-dsa-state-contract
branch
from
September 3, 2026 09:44
04f3398 to
52acb82
Compare
ShangmingCai
left a comment
Collaborator
There was a problem hiding this comment.
Need rebase.
Is this PR ready for review? If so, please convert it from draft to a ready PR.
Contributor
|
Thanks @IvanShan177. Closing this because it is still a draft and has not been updated in 30 days. Reopen it if the work is still relevant. Some directories moved recently, so an older branch may need retargeting: |
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
This is the first implementation slice of #37765 and contributes to the shared-protocol work tracked by #34510 and #33861.
DSA indexer state is request-scoped. Decode already builds its destination indices from the full logical input length and the device KV pool page size. Prefill currently reuses the generic full-KV helper, which is based on:
and the allocator page size. This couples DSA state shape to the locally materialized Prefill range and to an unqualified page-size domain. A cache-hit or chunked-Prefill transition can therefore produce a source state count different from the destination registered by Decode.
Changes
get_dsa_state_page_indices()as the shared request-scoped DSA index builder.extend_endis 64;The expected DSA payload contains three device pages. It is independent of the shorter Prefill extend range and the unrelated allocator page size.
Scope
This PR intentionally does not change the wire format or transport state machine. It also does not implement repacking between different Prefill and Decode device page sizes; that work remains tracked in #37765. The explicit request-role truth table is already covered by #34977 and is not duplicated here.
Validation
75 passed, 12 subtests passed.3 passed.git diff --check.Follow-ups
CI States
Latest PR Test (Base): ❌ Run #33740502212
Latest PR Test (Extra): ❌ Run #33740501887
Latest PR Test (AMD ROCm 7.2): ❌ Run #33740501912