Skip to content

[BugFix] Fix CPP profiling dummy prefill routing with PCP - #18622

Merged
weiguihua2 merged 7 commits into
vllm-project:mainfrom
dianWang325:bugfix/cpp_dummy
Oct 14, 2026
Merged

weiguihua2 merged 7 commits into
vllm-project:mainfrom
dianWang325:bugfix/cpp_dummy

Conversation

@dianWang325

@dianWang325 dianWang325 commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

What this PR does / why we need it?

CPP startup profiling calls the model runner dummy path with one synthetic request. With PCP enabled, the generic V2 dummy batch is initialized with decode-only attention state and the PCP dummy fast path bypasses partition_batch(). A large CPP profiling sample can therefore enter the PCP decode O-projection communication path without being partitioned, where its token rows exceed the decode buffer capacity.

This PR:

  • carries an explicit CPP-profile marker through the V2 model runner and input batch;
  • builds CPP dummy inputs with fresh-prefill metadata and PrefillNoCache attention state;
  • sends CPP profiling dummy batches through PCP partition_batch() while preserving ordinary capture/runtime dummy behavior;
  • skips the speculative drafter only for CPP profiling, matching the existing V1 behavior; and
  • adds unit coverage for CPP dummy construction, state restoration, and PCP partitioning.

Does this PR introduce any user-facing change?

Yes. CPP startup profiling now works with PCP-enabled V2 deployments instead of routing large profiling dummy batches through the decode-only PCP path. There is no CLI or configuration API change.

How was this patch tested?

Unit tests:

python -m pytest -q \
  tests/ut/worker/test_v2_dummy_padding.py \
  tests/ut/worker/test_pcp_manager_v2.py \
  tests/ut/worker/test_model_runner_v2.py \
  tests/ut/worker/test_worker_v2.py

Result: 240 passed, 14 warnings.

End-to-end validation used GLM-5.2 W4A8 with PP=2, TP=2, PCP=4, EP enabled, MTP=1, eager mode, and max_num_batched_tokens=20480:

  • CPP collected all 64 startup samples and reported Profiling completed successfully;
  • the service reached /health HTTP 200 without the previous decode-capacity ValueError;
  • AISBench warmup: 5/5 requests succeeded;
  • fixed-length prefill (65,536 input tokens, concurrency 2): 24/24 succeeded; and
  • variable-length prefill (40,960-81,920 input tokens, concurrency 2): 24/24 succeeded.

A CPP-disabled run of the same service and three workloads also completed with zero failed requests, covering the non-CPP path.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request addresses a bug where CPP startup profiling failed in PCP-enabled V2 deployments due to large profiling dummy batches being incorrectly routed through the decode-only path. By properly marking these batches and ensuring they undergo standard partitioning, the changes allow the system to handle these profiling requests as valid prefill operations, preventing buffer capacity issues and ensuring accurate latency profiling.

Highlights

  • CPP Profiling Logic: Introduced an explicit CPP-profile marker in the V2 model runner and input batch to distinguish profiling dummy requests from standard decode-only dummy batches.
  • PCP Partitioning Integration: Updated the PCP manager to ensure CPP profiling dummy batches are correctly processed through partition_batch() instead of bypassing it, preventing decode buffer capacity overflows.
  • Prefill Metadata Handling: Configured CPP dummy inputs to use fresh-prefill metadata and PrefillNoCache attention state, ensuring they accurately simulate real prefill requests.
  • Speculative Drafter Bypass: Implemented logic to skip the speculative drafter specifically for CPP profiling, maintaining consistency with V1 behavior.
New Features

🧠 You can now enable Memory (public preview) to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution. ↩

@github-actions

Copy link
Copy Markdown
Contributor

👋 Hi! Thank you for contributing to the vLLM Ascend project. The following points will speed up your PR merge:‌‌

  • A PR should do only one thing, smaller PRs enable faster reviews.
  • Every PR should include unit tests and end-to-end tests ‌to ensure it works and is not broken by other future PRs.
  • Write the commit message by fulfilling the PR description to help reviewer and future developers understand.

If CI fails, you can run linting and testing checks locally according Contributing and Testing.


Tip

💡 Consider Linking a Related Issue or RFC

Your PR title contains the [BugFix] tag, indicating a bug fix or new feature.

Linking a related issue or RFC in the PR description is strongly encouraged — it gives reviewers helpful context and speeds up the review. You can use any of these keywords:

  • Fixes #<issue_number>
  • Closes #<issue_number>
  • Resolves #<issue_number>
  • Refs #<rfc_or_issue_number> (for RFCs)

🙏 Thanks for helping us keep the project well-organized!

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces support for CPP (C++ Profiling) latency profiling by enabling synthetic prefill requests in the Ascend worker. It updates AscendInputBatch to handle CPP-specific metadata, modifies AscendPCPManager to partition these global prefill dummies correctly, and adds a context manager to ModelRunner to scope these changes. I have identified a high-severity issue where AscendPCPManager fails to override input_batch_cls, which will cause runtime assertion failures when instantiating dummy batches. Please define input_batch_cls = AscendInputBatch in AscendPCPManager to ensure the correct class is used.

Comment thread vllm_ascend/worker/v2/pcp_manager.py Outdated
Comment thread vllm_ascend/worker/v2/input_batch.py Outdated
@weiguihua2 weiguihua2 added the ready-precise run selected e2e test for pr label Oct 14, 2026
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
@weiguihua2
weiguihua2 merged commit eaca937 into vllm-project:main Oct 14, 2026
38 checks passed
zzzzwwjj pushed a commit that referenced this pull request Oct 14, 2026
…ith PCP (#18669)

### What this PR does / why we need it?

Backport of #18622 to `releases/v0.30.0`.

CPP startup profiling uses a single synthetic request. With PCP enabled,
the generic V2 dummy batch can otherwise retain decode-only attention
state and bypass PCP `partition_batch()`, allowing a large profiling
sample to enter the PCP decode O-projection communication path without
partitioning.

This backport:

- carries an explicit CPP-profile marker through the V2 model runner and
input batch;
- builds CPP dummy inputs with fresh-prefill metadata and
`PrefillNoCache` attention state;
- routes CPP profiling dummy batches through PCP `partition_batch()`;
- skips the speculative drafter only for CPP profiling, matching V1
behavior; and
- adds unit and E2E coverage for the affected path.

The PCP conflict was resolved against the v0.30.0
`partition_batch(input_batch, padded_num_tokens, padded_num_reqs)` API;
no main-only `BatchExecutionDescriptor` interface was introduced.

### Does this PR introduce _any_ user-facing change?

Yes. CPP startup profiling works with PCP-enabled V2 deployments instead
of routing large profiling dummy batches through the decode-only PCP
path. There is no CLI or configuration API change.

### How was this patch tested?

- `git diff --check upstream/releases/v0.30.0...HEAD`
- Python bytecode compilation for all modified Python files: passed
- Commit author, committer, and DCO sign-off verified for all six
backported commits

The targeted unit suite could not run in the local Windows checkout
because that environment does not have `torch` installed
(`ModuleNotFoundError: No module named 'torch'`). CI is expected to run
the complete tests in the supported environment.

Original PR validation: #18622

- vLLM main:
vllm-project/vllm@ced6857

---------

Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
@czydyy

czydyy commented Oct 15, 2026

Copy link
Copy Markdown
Collaborator

Hi @dianWang325, the nightly Daily test for vllm-ascend reported failures (failed on: a3-2 card-(part 5-5), a3-4 card-(part 4-5), a3-4 card-(part 2-5), Kimi-K2.6-w4a8-A3). Could you please check whether your recent merge (#18622) might have introduced these failures? Thanks!

Failed run(s):
https://github.com/vllm-project/vllm-ascend/actions/runs/38657430708
https://github.com/vllm-project/vllm-ascend/actions/runs/38658117245

ningjingbengxiaohai pushed a commit that referenced this pull request Oct 15, 2026
…tibility (#18229)

### What this PR does / why we need it?

Upgrade the release dependency from vLLM v0.30.0 to
[v0.31.0](https://github.com/vllm-project/vllm/commit/db9527a46873454610df6dbedf79a36d6bf1a7f6)
while keeping the independently supported verified-main target at
[c4df37d](https://github.com/vllm-project/vllm/commit/c4df37dfcc7f72ca41cd43801a468526ecf99a2b).
Rebase on latest Ascend main `c2382c6`, preserving the CPP profiling
changes from #18622. The file mapping below describes the diff for
`23c8b15` against `c2382c6`.

The two targets have different APIs despite both being supported: retain
version-dependent forwarding for profiling randomization, PP batch
lengths, Mamba allocation, EPLB setup and encoder-only prefill
admission. Remove obsolete 0.30 branches only where both targets now
share the contract.

| Contract | Verified main `c4df37d` | Release v0.31.0 `db9527a` |
| --- | --- | --- |
| Profiling | Parent calls omit `randomize_inputs` | Forward the flag
through V1/V2/310P and MC2 |
| PP batch state | No `max_seq_len_np` | Preserve the field in
`AscendInputBatch` |
| Mamba allocation | Parent has no `prefill_end` | Forward checkpoint
boundary |
| EPLB setup | Update existing state/communicator | Construct state from
model and mapping |
| Non-chunked prefill | Keep encoder-only budget exception | Keep
release budget rejection |

#### Changes organized by downstream file

Upstream links identify the reason or contract being adapted. For
existing main behavior that becomes common to both targets, the change
is removal of the old release branch, not a new port of the complete
upstream implementation. File links are pinned to this PR head; [the
complete fixed
diff](https://github.com/vllm-project/vllm-ascend/compare/c2382c67aa6be12f1c822733cd47d021f61b0b23...23c8b15c2709978463490b0e8531bf5f9f27b9c1)
shows the exact edits.

<details>
<summary>Dependency markers, images and documentation (13
files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`.github/vllm-release-tag.commit`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/.github/vllm-release-tag.commit)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Advance the release marker
to `v0.31.0`; leave the verified-main marker at `c4df37d`. |
|
[`Dockerfile`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.310p`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.310p)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.310p.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.310p.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a3`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a3)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a3.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a3.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a5`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a5)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a5.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a5.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`README.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/README.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Update the release CI
support version to 0.31.0. |
|
[`README.zh.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/README.zh.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Update the Chinese release
CI support version to 0.31.0. |
|
[`docs/source/tutorials/models/DeepSeek-V4.1-Flash.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/docs/source/tutorials/models/DeepSeek-V4.1-Flash.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Use separate release and
verified-main marker commands for the two build targets. |
|
[`vllm_ascend/ops/triton/docs/v2/spec_decode/prepare_dflash_inputs.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/triton/docs/v2/spec_decode/prepare_dflash_inputs.md)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Update the documented
DFlash ABI version to 0.31.0; no new kernel behavior is introduced by
this document change. |

</details>

<details>
<summary>Model runners, graphs and platform integration (14
files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/_310p/model_runner_310p.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/model_runner_310p.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls. | Forward the profiling randomization flag through the 310P V1
override to the NPU V1 runner. |
|
[`vllm_ascend/_310p/worker/v2/model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/model_runner.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent. | Forward release-only
randomization; accept `num_active_loras` in the common prepare
signature, use the shared PCP/input-batch contract and compute complete
prompt-tail/decode-graph metadata in CPU input preparation. |
|
[`vllm_ascend/_310p/worker/v2/sampler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/sampler.py)
| [vLLM #56497](https://github.com/vllm-project/vllm/pull/56497)
introduces V2 `LogitsContext` and custom logits-processor lifecycle;
`Sampler.add_request` no longer takes `prompt_len`. | Adopt
`add_request(req_idx, sampling_params)` and remove the legacy
prompt-length argument; retain the 310P CPU generator/sampling
implementation. |
|
[`vllm_ascend/attention/attention_v1.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/attention/attention_v1.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility. | Remove the 0.30 condition around
V2 speculative-padding handling while retaining actual prefill/decode
metadata semantics. |
|
[`vllm_ascend/patch/worker/patch_v2/patch_model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_v2/patch_model_runner.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist.<br><br>[vLLM
#45635](https://github.com/vllm-project/vllm/pull/45635) moves
routed-expert output to `AuxOutputConfig`/the AuxOutput connector; [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) removes the
legacy runner initialization keyword. | Read `dcp_sharded` from cache
specs and forward it to block tables; initialize the AuxOutput connector
from `aux_output_config.enabled`; drop the legacy `attn_cg_support`
keyword. |
|
[`vllm_ascend/platform.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/platform.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635) moves
routed-expert output to `AuxOutputConfig`/the AuxOutput connector; [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) removes the
legacy runner initialization keyword. | Apply the existing V1 AuxOutput
configuration guard to both targets, removing the old 0.30 early return.
|
|
[`vllm_ascend/worker/model_runner_v1.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/model_runner_v1.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls. | Accept `randomize_inputs` in profiling/dummy execution and
enter `maybe_randomize_inputs` inside forward context when requested;
preserve the Ascend execution path. |
|
[`vllm_ascend/worker/v2/aclgraph_utils.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/aclgraph_utils.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980)
replaces the legacy PCP helper with descriptor-based `partition_batch`,
restores auxiliary hidden states with sampling outputs, and renames the
DCP preparation helper.<br><br>[vLLM
#57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Use
`prepare_dcp_local_seq_lens`; delegate model-wrapper attribute lookup to
the original model so DFlash context-KV callbacks remain accessible. |
|
[`vllm_ascend/worker/v2/input_batch.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/input_batch.py)
| [vLLM #58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture. | Always retain
prompt-tail and graph-eligibility fields and forward dummy-batch
`max_query_len`/`is_padding`; remove obsolete 0.30 branches. |
|
[`vllm_ascend/worker/v2/model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/model_runner.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58542](https://github.com/vllm-project/vllm/pull/58542) adds
`max_seq_len_np` for PP sampled-token broadcast handling. Present in
release batch state; absent from pinned main.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) replaces the
legacy PCP helper with descriptor-based `partition_batch`, restores
auxiliary hidden states with sampling outputs, and renames the DCP
preparation helper.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent.<br><br>[vLLM
#54335](https://github.com/vllm-project/vllm/pull/54335) routes
fixed-token scoring through the same unpadded logits path as prompt
logprobs, which is incompatible with Ascend lmhead-TP collective row
layouts. | Use release-only kwargs for profiling/execute and MC2 dummy
execution; forward release-only `max_seq_len_np`. After PD request
reclassification, recompute `has_prefill`, decode-graph eligibility and
uniform token count. Accept `num_active_loras` in the common prepare
signature without adding FastPrefillHelper behavior. Use
descriptor-based PCP partitioning and restore auxiliary states before
replicated drafting. Extend the lmhead-TP guard to fixed-token scoring,
tolerating workers without `token_id_scores`. |
|
[`vllm_ascend/worker/v2/model_states/mamba_hybrid.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/model_states/mamba_hybrid.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400)
requires decode-like prompt tails to use decode-row Mamba metadata for
speculative rollback. | Build a local mask `is_prefilling_np &
~prefill_runs_as_decode_np` so prompt tails are decode rows; do not
mutate the batch's original prefill mask. |
|
[`vllm_ascend/worker/v2/pcp_manager.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/pcp_manager.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980)
replaces the legacy PCP helper with descriptor-based `partition_batch`,
restores auxiliary hidden states with sampling outputs, and renames the
DCP preparation helper. | Unify descriptor-based partitioning, including
CPP profile capture after #18622, and the `(batch, hidden, aux)`
sampling restore contract; restore and trim auxiliary states together
with hidden states to the unpadded global token extent. |
|
[`vllm_ascend/worker/v2/spec_decode/autoregressive/aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/spec_decode/autoregressive/aclgraph.py)
| [vLLM #58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture. | Always pass
`desc.max_query_len or desc.uniform_token_count` to autoregressive
capture. |
|
[`vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Always receive and forward
`precompute_context_kv` under the Ascend communicator/model-capture
wrappers. |

</details>

<details>
<summary>KV allocation and block tables (6 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/_310p/worker/v2/block_table.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/block_table.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist.<br><br>[vLLM
#56734](https://github.com/vllm-project/vllm/pull/56734) uses
`idx_mapping=-1` for dummy draft/padding requests and masks their
persistent block-table reads to avoid stale-row KV writes. | Unify the
constructor with `dcp_sharded`; skip negative request indices and retain
PAD slots in the CPU mapping path. Keep the existing CP=1 restriction
and persistent CPU/device buffers. |
|
[`vllm_ascend/models/glm5next/kv_cache.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/models/glm5next/kv_cache.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) adds
`prefill_end` to Mamba checkpoint allocation, including prompt-end
retention. Release has the new signature; pinned main has the old one. |
Accept `prefill_end` for call compatibility; keep one private Kpool tail
block per request. |
|
[`vllm_ascend/ops/triton/v2/block_table/compute_slot_mappings.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/triton/v2/block_table/compute_slot_mappings.py)
| [vLLM #56734](https://github.com/vllm-project/vllm/pull/56734) uses
`idx_mapping=-1` for dummy draft/padding requests and masks their
persistent block-table reads to avoid stale-row KV writes. | Unify the
slot-mapping kernel, mask block-table loads with `is_real_req`, and emit
PAD for dummy rows; retain Ascend block/window and address-calculation
behavior. |
|
[`vllm_ascend/patch/platform/patch_kv_cache_utils.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_kv_cache_utils.py)
| The pinned `_annotate_eagle_groups` contract uses
`use_trailing_layer_fallback`, replacing the DeepSeek-V4-specific
fallback keyword; the introducing PR was not independently identified.
Fixed contracts: [release:
kv_cache_utils.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/kv_cache_utils.py#L2170).
| Always pass `use_trailing_layer_fallback=True`; retain existing Ascend
cache grouping/annotation behavior. |
|
[`vllm_ascend/patch/platform/patch_mamba_manager.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_mamba_manager.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) adds
`prefill_end` to Mamba checkpoint allocation, including prompt-end
retention. Release has the new signature; pinned main has the old one. |
Accept `prefill_end`, forwarding it only to the release parent while
retaining the existing Ascend allocation logic. |
|
[`vllm_ascend/worker/v2/block_table.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/block_table.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist. | Use one
constructor with optional per-group `dcp_sharded` validation/forwarding;
retain Ascend int32 slot mappings. |

</details>

<details>
<summary>Schedulers and profiling (5 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/core/dyntra_lb_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/dyntra_lb_scheduler.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#58259](https://github.com/vllm-project/vllm/pull/58259) define the
upstream resumable-session queue/handoff lifecycle: stopping a turn can
re-enqueue buffered continuation input.<br><br>Both targets admit
against `max_num_active_reqs` and include parked streaming sessions in
occupied slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Use KV-holder-first queue selection/re-enqueueing, the common
blocked-request helper, deferred bookkeeping and active-slot admission
including parked streams. Preserve the main-only encoder exception.
Remove secondary stop cleanup so upstream can retain/re-enqueue
resumable continuations. |
|
[`vllm_ascend/core/recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/recompute_scheduler.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>Both targets admit against
`max_num_active_reqs` and include parked streaming sessions in occupied
slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Fold the legacy queues into the common KV-holder/deferred path, count
parked streams for active admission, and preserve the version-dependent
encoder condition. Remove the redundant remote-KV waiting debug log as a
local cleanup. |
|
[`vllm_ascend/core/scheduler_profiling_chunk.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/scheduler_profiling_chunk.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>Both targets admit against
`max_num_active_reqs` and include parked streaming sessions in occupied
slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Use the common blocked-request/queue lifecycle, active admission
including parked streams, and the version-dependent encoder budget
condition. |
|
[`vllm_ascend/patch/platform/patch_balance_schedule.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_balance_schedule.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses `_handle_blocked_waiting_request`. |
Fold six obsolete 0.30 queue branches and add the release/main encoder
budget condition. Document the shared `if not request_queue`
drained-queue guard. Retain baseline balancing, running-only DP
snapshots/admission accounting and connector-snapshot cleanup; complete
upstream schedule synchronization is outside this patch. |
|
[`vllm_ascend/profiling_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/profiling_config.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947)
replaces `skipped_waiting` with `kv_holding_waiting` and
`deferred_waiting`, prioritizes KV holders, and uses
`_handle_blocked_waiting_request`. | Retarget the profiling wrapper from
the old blocked-status promotion helper to
`_handle_blocked_waiting_request`. |

</details>

<details>
<summary>EPLB state and routing (2 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/distributed/eplb/eplb_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/distributed/eplb/eplb_state.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) changes
main's EPLB setup to update existing state and reuse its communicator.
Release still creates state from `(model, model_config, mapping)`. |
After the parent's `update_mapping`, refresh Ascend replica routing
tables; consistently resolve an unspecified NPU device index to the
current device. |
|
[`vllm_ascend/worker/v2/eplb.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/eplb.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) changes
main's EPLB setup to update existing state and reuse its communicator.
Release still creates state from `(model, model_config, mapping)`. |
Create `AscendEplbState` on release with the current policy/optional
expert arguments; call the main parent to update the existing state and
communicator. |

</details>

<details>
<summary>Models and MoE operators (6 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/models/kimi_k3.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/models/kimi_k3.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592)/[vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) use
`prefix_delta` and the three-value AttnRes layer contract instead of the
old prepared-input/deferred-MLP contract. | Remove old layer/model
contracts, propagate `prefix_delta` and return the three-value AttnRes
state; preserve Ascend fused operations, DSpark aux selection and SP/PP
transport/output boundaries. |
|
[`vllm_ascend/ops/fused_moe/gate_linear.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/fused_moe/gate_linear.py)
| [vLLM #58234](https://github.com/vllm-project/vllm/pull/58234) unifies
MoE gate layers under `GateLinear` with the current linear constructor
and replaces Step3.5's dedicated FP32 gate class. | Use the current
constructor parameters (`skip_bias_add`, `quant_config`, `return_bias`)
and retain BF16-to-FP32 gate/fallback semantics. CRLF-to-LF
normalization contributes to the large line diff. |
|
[`vllm_ascend/ops/fused_moe/router/grouped_topk_router.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/fused_moe/router/grouped_topk_router.py)
| [vLLM #58880](https://github.com/vllm-project/vllm/pull/58880) removes
`routed_scaling_factor` from routing-method classification, allowing
MiniMax classification with non-unit scaling. | Stop passing
`routed_scaling_factor` to classification; downstream routing-weight
scaling is retained. |
|
[`vllm_ascend/patch/__init__.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/__init__.py)
| The release target is 0.31.0; [vLLM
#56994](https://github.com/vllm-project/vllm/pull/56994) is context for
the retained GLM reasoning patch comment, not a new model capability in
this PR. | Update only the supported-version comment for the retained
GLM reasoning patch. |
|
[`vllm_ascend/patch/worker/patch_step3p5.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_step3p5.py)
| [vLLM #58234](https://github.com/vllm-project/vllm/pull/58234) unifies
MoE gate layers under `GateLinear` with the current linear constructor
and replaces Step3.5's dedicated FP32 gate class. | Always use
`GateLinear` with FP32 parameter/output types instead of the legacy
FP32ReplicatedLinear branch. |

</details>

<details>
<summary>Token scoring and Triton helpers (2 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/patch/worker/patch_triton.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_triton.py)
| [vLLM #58651](https://github.com/vllm-project/vllm/pull/58651) uses
`triton.next_power_of_2` in packed-QK RoPE constexpr evaluation; the
Ascend replacement must also satisfy the installed Triton
JIT/constexpr-function contract. | Use a constexpr-aware
`next_power_of_2` replacement; register with `triton.constexpr_function`
when available, otherwise unwrap `tl.constexpr.value` in the fallback. |
|
[`vllm_ascend/worker/v2/sample/logprob.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/sample/logprob.py)
| [vLLM #54335](https://github.com/vllm-project/vllm/pull/54335) adds
fixed-token prompt scoring and broadcasts candidate IDs with `expand`;
the token-ID row stride can be zero or non-contiguous. | Pass
`token_ids.stride(0)` into the Triton kernel and use it for row
addressing; support broadcast stride zero and strided candidate IDs. |

</details>

BalanceScheduler scope: this PR folds the old queue branches and adapts
encoder-only admission. Its baseline DP balancing, running-only
snapshot/accounting and connector-snapshot cleanup remain; complete
scheduler-body synchronization and a strict AST equivalence requirement
are deferred. The baseline drift guard may skip and does not prove
complete upstream equivalence.

### Does this PR introduce _any_ user-facing change?

The default release dependency becomes vLLM v0.31.0; the verified-main
pin remains unchanged. Fixed-token prompt scoring handles
broadcast/strided IDs correctly and reports an explicit error when used
with unsupported lmhead TP. Resumable Dyntra continuations retain
upstream stop/queue behavior, and PD prompt-tail graph/Mamba metadata
follow the supported upstream contracts.

### How was this patch tested?

#### Test changes organized by file

The table describes test intent and fixture changes; it does not claim
that every changed test was selected or executed on NPU hardware.

<details>
<summary>Unit, PR E2E and nightly test mapping (37 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_compute_token_logprobs.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_compute_token_logprobs.py)
| [vLLM #54335](https://github.com/vllm-project/vllm/pull/54335) | Add
NPU numerical comparisons for broadcast stride=0 and sliced stride=8
token IDs; outside the PR CI selector. |
|
[`tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_num_nans.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_num_nans.py)
| Release-version cleanup; no new upstream behavior. | Update the
default version label to 0.31.0; no algorithm change. |
|
[`tests/e2e/pull_request/four_card/test_kimi_k3.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/four_card/test_kimi_k3.py)
| [vLLM #54222](https://github.com/vllm-project/vllm/pull/54222) | Check
equality between P-worker `remote_prefill_cached_tokens` and the
response cache count; zero hits are valid for a new prompt. |
|
[`tests/e2e/pull_request/one_card/test_model_runner_v1_with_device.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/one_card/test_model_runner_v1_with_device.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Use the
common AuxOutput configuration object in V1 guard fixtures. |
|
[`tests/e2e/pull_request/one_card/test_thinking_budget.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/one_card/test_thinking_budget.py)
| [vLLM #56497](https://github.com/vllm-project/vllm/pull/56497) |
Construct `LogitsContext` with expanded mapping, input IDs, positions
and sequence bounds; call `apply(logits, ctx)`. |
|
[`tests/ut/_310p/test_model_runner_v2_310p.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/_310p/test_model_runner_v2_310p.py)
| [vLLM #56456](https://github.com/vllm-project/vllm/pull/56456), [vLLM
#56497](https://github.com/vllm-project/vllm/pull/56497) | Use the
current sampler request signature and pass the added prepare-input LoRA
argument in 310P fixtures. |
|
[`tests/ut/attention/test_mla_cp.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/attention/test_mla_cp.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Mock `get_dcp_world_size_and_rank` and
remove legacy DCP group fixture branching. |
|
[`tests/ut/core/test_circular_buffer.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_circular_buffer.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Pass `replay_boundaries=[tokens-1]` to the current cache-block API. |
|
[`tests/ut/core/test_dyntra_lb_recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_dyntra_lb_recompute_scheduler.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) | Use
the shared KV-holder/deferred queue interfaces in Dyntra/recompute
fixtures. |
|
[`tests/ut/core/test_dyntra_lb_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_dyntra_lb_scheduler.py)
| [vLLM #58259](https://github.com/vllm-project/vllm/pull/58259), [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) | Regress
synchronous/asynchronous resumable continuation handling for running,
paused and preempted requests, buffered/unbuffered input, and final
cleanup; update queue seams. |
|
[`tests/ut/core/test_profiling_chunk.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_profiling_chunk.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934), [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) | Update queue
fixtures/blocked-request helper and active-request capacity field. |
|
[`tests/ut/core/test_recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_recompute_scheduler.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) |
Remove legacy queue branching and use the shared blocked-request seam. |
|
[`tests/ut/core/test_scheduler_connector_block_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_scheduler_connector_block_state.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947), [vLLM
#59029](https://github.com/vllm-project/vllm/pull/59029) | Supply the
baseline `balance_queue` fixture; connector-snapshot cleanup itself
predates this change. |
|
[`tests/ut/distributed/eplb/test_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/distributed/eplb/test_state.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) |
Verify mapping updates refresh Ascend routing tables. |
|
[`tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) | Use
the shared queue lifecycle rather than version-specific skipped-waiting
fixtures. |
|
[`tests/ut/kv_offload/test_preempt_offload_connector.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/kv_offload/test_preempt_offload_connector.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Always provide prefix replay and request token-count fields in the
offload fixture. |
|
[`tests/ut/models/test_deepseek_v41_release_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_deepseek_v41_release_config.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Assert obsolete flattened multimodal-prefix flags are absent after
architecture conversion. |
|
[`tests/ut/models/test_glm5next_kv_cache.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_glm5next_kv_cache.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) | Pass
the new allocation argument while checking the private-tail block
policy. |
|
[`tests/ut/models/test_kimi_k3_adapter.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_kimi_k3_adapter.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592), [vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) | Update layer
signatures/three-value returns, auxiliary output expectations and
AST-extracted fixtures. |
|
[`tests/ut/models/test_kimi_k3_pp_sp.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_kimi_k3_pp_sp.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592), [vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) | Use the
common Kimi AttnRes contract in PP/SP checks. |
|
[`tests/ut/patch/platform/test_patch_balance_schedule.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_patch_balance_schedule.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947), [vLLM
#59029](https://github.com/vllm-project/vllm/pull/59029) | Use common
queue fixtures; add eight encoder/chunked/prompt-budget cases and
empty/fully deferred queue regressions with/without KV blocks. Correct
the structural guard assertion to `if not request_queue`. Keep the
baseline AST drift check, which can skip. |
|
[`tests/ut/patch/platform/test_patch_engram_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_patch_engram_config.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Expect shared-memory default resolution for this supported fixture
configuration; no universal shared-memory default is claimed. |
|
[`tests/ut/patch/platform/test_prefix_cache_cp_patches.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_prefix_cache_cp_patches.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) |
Supply an explicit `prefill_end` allocation boundary. |
|
[`tests/ut/spec_decode/test_eagle_proposer.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/spec_decode/test_eagle_proposer.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Use the current model-config multimodal
capability interface and remove obsolete skips/branches. |
|
[`tests/ut/spec_decode/test_mla_dspark.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/spec_decode/test_mla_dspark.py)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) |
Assert DFlash context-KV callback forwarding and the shared capture
signature. |
|
[`tests/ut/test_minimax_m3_kv_block_size.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/test_minimax_m3_kv_block_size.py)
| Release-version cleanup; no new upstream behavior. | Remove only an
unused version-helper import. |
|
[`tests/ut/test_platform.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/test_platform.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Use the
current AuxOutput configuration guard for both target versions. |
|
[`tests/ut/worker/test_attn_utils_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_attn_utils_v2.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Initialize `model_state.model_config`
instead of assigning the read-only length property. |
|
[`tests/ut/worker/test_dcp_speculator_metadata_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_dcp_speculator_metadata_v2.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Assert prefill metadata over the padded
request extent. |
|
[`tests/ut/worker/test_model_runner_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58542](https://github.com/vllm-project/vllm/pull/58542) adds
`max_seq_len_np` for PP sampled-token broadcast handling. Present in
release batch state; absent from pinned main.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) replaces the
legacy PCP helper with descriptor-based `partition_batch`, restores
auxiliary hidden states with sampling outputs, and renames the DCP
preparation helper.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent.<br><br>[vLLM
#54335](https://github.com/vllm-project/vllm/pull/54335) routes
fixed-token scoring through the same unpadded logits path as prompt
logprobs, which is incompatible with Ascend lmhead-TP collective row
layouts.<br><br>[vLLM
#58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Cover release/main kwargs and PP fields, PD
graph reclassification, PCP auxiliary restoration and lmhead scoring
guards; update model-state fixtures. |
|
[`tests/ut/worker/test_model_runner_v2_encoder_decoder.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2_encoder_decoder.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Update model-state length fixtures through
model configuration. |
|
[`tests/ut/worker/test_model_runner_v2_mamba.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2_mamba.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) |
Regress prompt-tail masks for FULL/NONE graph modes and zero/three draft
tokens; verify the original mask is unchanged. |
|
[`tests/ut/worker/test_pcp_manager_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_pcp_manager_v2.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Assert
descriptor-based partitioning and hidden/aux restore layout; update
AuxOutput fixture configuration. |
|
[`tests/ut/worker/test_v2_dummy_padding.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_v2_dummy_padding.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture.<br><br>[vLLM
#58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Use the model-config-backed state/dummy
descriptor contract and retain graph-eligibility metadata. |
|
[`tests/ut/worker/v2/test_aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_aclgraph.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980), [vLLM
#58275](https://github.com/vllm-project/vllm/pull/58275) | Update
capture descriptors and dummy-batch keyword expectations. |
|
[`tests/ut/worker/v2/test_eplb_controller.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_eplb_controller.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) | Cover
release state construction versus main in-place state/communicator
reuse. |
|
[`tests/ut/worker/v2/test_eplb_load_collection_phase.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_eplb_load_collection_phase.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) | Match
each target's EPLB setup signature in load-collection fixtures. |

</details>

#### Local A3 nightly validation (2026-10-15; frozen head `444e962`)

These four model runs used **`444e962b239c3a8fc56b9255d601818e6e028b9a`
+ vLLM 0.31.0 (`db9527a`)**, which is also the restored PR head; the
deferred connector hardening is not included. Prefill 138 + Decode 136,
16 NPUs per node; original image, weights, datasets, launch and
benchmark parameters were retained, with only the second-node address
mapped from 139 to 136. All four cases exited pytest 0 on both nodes
(one passed JUnit case per node). OTT is output token/s; TPOT/TTFT are
ms.

| Case | Performance requests | OTT / required minimum | TPOT / TTFT |
AIME2025 accuracy | Result |
| --- | --- | --- | --- | --- | --- |
| Kimi-K2.6 PD | 60/60 | 355.1593 / 337.024075 | 20.5 / 3268.2 | 90%,
within 93.33±10 | Performance + accuracy passed |
| DeepSeek-V4 Flash PD-prefix | Accuracy only | N/A | N/A | 90%, within
90±10 | Accuracy passed |
| GLM-5.1 W8A8C8 128K | 256/256 | 811.7645 / 282.105876 | 39.8 / 32665.6
| No accuracy item | Performance passed |
| MiniMax-M2.7 PD-prefix | 160/160 | 711.0518 / 698.497 | 34.8 / 17438.2
| 90%, within 93.33±10 | Performance + accuracy passed |

All performance requests above, and the valid controls below, were
checked for actual 1024-token outputs, not just success flags.

**Conditional controls:** historical throughput differences triggered
only the affected performance cases against the same PR base `6d1dd70`,
without this PR, + vLLM 0.30.0 (`ced6857`). Kimi: 355.1593 vs 359.8514
OTT (**-1.30%**); the earlier 7.27% loss was not reproduced in this
comparison. TPOT was 20.5 vs 19.7ms (+0.8ms/+4.06%), and average request
latency +3.48%; a single pair does not establish latency equivalence or
a stable regression. GLM: 811.7645 vs 813.3506 OTT (**-0.20%**), TPOT
39.8 vs 39.4ms. Kimi's original random request pacing affects aggregate
OTT. No alternating reruns or unaffected-model 0.30 controls were added.

Archived evidence:
`main2main-nightly-20261013/pr18229-update-444e962-20261015/`
(`FINAL_REPORT.md`, per-node logs/JUnit, raw AISBench outputs,
token-count audit, controls and diagnostic evidence). Both nodes were
released after testing.

#### Deferred follow-up: multi-group receive-failure reporting (not
included)

The request-level receive-failure hardening change has been removed from
this upgrade PR; the branch is restored to the nightly-tested head
`444e962`. The original four nightlies already passed on this head
**without** that fix, so it is not required for these normal-path
workloads to pass.

The fault-path issue remains real: if a multi-group receive actually
fails, the existing connector can report flat block IDs and trigger the
vLLM 0.31 scheduler guard, terminating Decode EngineCore. This is
handled separately in
[#18823](https://github.com/vllm-project/vllm-ascend/pull/18823),
retaining ordinary non-HMA block-level recovery semantics. The upgrade
PR does not claim fault isolation is fixed.

Development fault-injection results belong to the deferred connector
implementation, not this restored head. No new NPU run was performed
when restoring the exact previously tested code.

#### Historical validation for head `23c8b15`

- New [E2E
workflow](https://github.com/vllm-project/vllm-ascend/actions/runs/38562748688)
and [Docs link
check](https://github.com/vllm-project/vllm-ascend/actions/runs/38562748395)
were triggered after the rebase. Results are pending; previous-head CI
does not validate this rebased head.
- A targeted [comment
command](https://github.com/vllm-project/vllm-ascend/pull/18229#issuecomment-6168149194)
requests `test_deepseek_v4_mtp_full_decode_only` against both supported
upstream targets. The [command
workflow](https://github.com/vllm-project/vllm-ascend/actions/runs/38562831465)
is queued; its actual test results remain pending.
- Ruff check and format check passed for all 72 changed Python files;
Python compilation and diff checks passed. Source-extracted execution of
both real CPP routing regressions passed against the required partition
signatures of the exact main/release refs. This validates dispatch
contracts with lightweight dependency stubs and does not replace full
pytest or NPU execution.
- Existing source-extracted scheduler regressions passed on both version
lanes: eight budget scenarios, two queue paths and empty/fully deferred
queue regressions, including negative controls.
- Local full pytest/Torch/NPU and `bash format.sh ci` remain unavailable
in this Windows environment. They require CI validation.
- Previous head `9330488` passed pre-commit, Docs and both CPU UT lanes
(main 10782 passed / 114 skipped; release 10784 passed / 112 skipped).
Its initial NPU matrix passed 41/42 shards; the remaining main A3 shard
failed in unchanged upstream teardown with `psutil.NoSuchProcess`,
before the MTP golden acceptance assertion. The consequent gate failure
and old-head rerun are historical evidence, not a result for the current
head.

#### Coverage limits and historical evidence

The PR CI selector scans `tests/ut` and `tests/e2e/pull_request`; the
new broadcast/strided token-logprob numerical tests under
`tests/e2e/nightly` are outside that selection. A5, standalone
upstream-worker and coverage-upload jobs were skipped in the inspected
run. Skips are not coverage. No dedicated packed-QK RoPE or V1
profiling-randomization standalone UT is added by this final diff.

Previous head `15f8a3d` passed
[E2E](https://github.com/vllm-project/vllm-ascend/actions/runs/38511018361)
and
[Docs](https://github.com/vllm-project/vllm-ascend/actions/runs/38511018193),
including 42 NPU jobs. Its PR-recorded CPU counts were 10574 passed /
113 skipped for verified main and 10576 passed / 111 skipped for
release, with no failures. Those counts belong to that historical head
and are not asserted as current-head counts.

- vLLM main:
https://github.com/vllm-project/vllm/commit/c4df37dfcc7f72ca41cd43801a468526ecf99a2b

---------

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Co-authored-by: shenzhao <shenzhao9@huawei.com>
tangdafu pushed a commit to tangdafu/vllm-ascend that referenced this pull request Oct 16, 2026
…tibility (vllm-project#18229)

### What this PR does / why we need it?

Upgrade the release dependency from vLLM v0.30.0 to
[v0.31.0](https://github.com/vllm-project/vllm/commit/db9527a46873454610df6dbedf79a36d6bf1a7f6)
while keeping the independently supported verified-main target at
[c4df37d](https://github.com/vllm-project/vllm/commit/c4df37dfcc7f72ca41cd43801a468526ecf99a2b).
Rebase on latest Ascend main `c2382c6`, preserving the CPP profiling
changes from #18622. The file mapping below describes the diff for
`23c8b15` against `c2382c6`.

The two targets have different APIs despite both being supported: retain
version-dependent forwarding for profiling randomization, PP batch
lengths, Mamba allocation, EPLB setup and encoder-only prefill
admission. Remove obsolete 0.30 branches only where both targets now
share the contract.

| Contract | Verified main `c4df37d` | Release v0.31.0 `db9527a` |
| --- | --- | --- |
| Profiling | Parent calls omit `randomize_inputs` | Forward the flag
through V1/V2/310P and MC2 |
| PP batch state | No `max_seq_len_np` | Preserve the field in
`AscendInputBatch` |
| Mamba allocation | Parent has no `prefill_end` | Forward checkpoint
boundary |
| EPLB setup | Update existing state/communicator | Construct state from
model and mapping |
| Non-chunked prefill | Keep encoder-only budget exception | Keep
release budget rejection |

#### Changes organized by downstream file

Upstream links identify the reason or contract being adapted. For
existing main behavior that becomes common to both targets, the change
is removal of the old release branch, not a new port of the complete
upstream implementation. File links are pinned to this PR head; [the
complete fixed
diff](https://github.com/vllm-project/vllm-ascend/compare/c2382c67aa6be12f1c822733cd47d021f61b0b23...23c8b15c2709978463490b0e8531bf5f9f27b9c1)
shows the exact edits.

<details>
<summary>Dependency markers, images and documentation (13
files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`.github/vllm-release-tag.commit`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/.github/vllm-release-tag.commit)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Advance the release marker
to `v0.31.0`; leave the verified-main marker at `c4df37d`. |
|
[`Dockerfile`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.310p`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.310p)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.310p.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.310p.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a3`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a3)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a3.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a3.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a5`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a5)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a5.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a5.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`README.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/README.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Update the release CI
support version to 0.31.0. |
|
[`README.zh.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/README.zh.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Update the Chinese release
CI support version to 0.31.0. |
|
[`docs/source/tutorials/models/DeepSeek-V4.1-Flash.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/docs/source/tutorials/models/DeepSeek-V4.1-Flash.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Use separate release and
verified-main marker commands for the two build targets. |
|
[`vllm_ascend/ops/triton/docs/v2/spec_decode/prepare_dflash_inputs.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/triton/docs/v2/spec_decode/prepare_dflash_inputs.md)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Update the documented
DFlash ABI version to 0.31.0; no new kernel behavior is introduced by
this document change. |

</details>

<details>
<summary>Model runners, graphs and platform integration (14
files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/_310p/model_runner_310p.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/model_runner_310p.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls. | Forward the profiling randomization flag through the 310P V1
override to the NPU V1 runner. |
|
[`vllm_ascend/_310p/worker/v2/model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/model_runner.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent. | Forward release-only
randomization; accept `num_active_loras` in the common prepare
signature, use the shared PCP/input-batch contract and compute complete
prompt-tail/decode-graph metadata in CPU input preparation. |
|
[`vllm_ascend/_310p/worker/v2/sampler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/sampler.py)
| [vLLM #56497](https://github.com/vllm-project/vllm/pull/56497)
introduces V2 `LogitsContext` and custom logits-processor lifecycle;
`Sampler.add_request` no longer takes `prompt_len`. | Adopt
`add_request(req_idx, sampling_params)` and remove the legacy
prompt-length argument; retain the 310P CPU generator/sampling
implementation. |
|
[`vllm_ascend/attention/attention_v1.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/attention/attention_v1.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility. | Remove the 0.30 condition around
V2 speculative-padding handling while retaining actual prefill/decode
metadata semantics. |
|
[`vllm_ascend/patch/worker/patch_v2/patch_model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_v2/patch_model_runner.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist.<br><br>[vLLM
#45635](https://github.com/vllm-project/vllm/pull/45635) moves
routed-expert output to `AuxOutputConfig`/the AuxOutput connector; [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) removes the
legacy runner initialization keyword. | Read `dcp_sharded` from cache
specs and forward it to block tables; initialize the AuxOutput connector
from `aux_output_config.enabled`; drop the legacy `attn_cg_support`
keyword. |
|
[`vllm_ascend/platform.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/platform.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635) moves
routed-expert output to `AuxOutputConfig`/the AuxOutput connector; [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) removes the
legacy runner initialization keyword. | Apply the existing V1 AuxOutput
configuration guard to both targets, removing the old 0.30 early return.
|
|
[`vllm_ascend/worker/model_runner_v1.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/model_runner_v1.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls. | Accept `randomize_inputs` in profiling/dummy execution and
enter `maybe_randomize_inputs` inside forward context when requested;
preserve the Ascend execution path. |
|
[`vllm_ascend/worker/v2/aclgraph_utils.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/aclgraph_utils.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980)
replaces the legacy PCP helper with descriptor-based `partition_batch`,
restores auxiliary hidden states with sampling outputs, and renames the
DCP preparation helper.<br><br>[vLLM
#57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Use
`prepare_dcp_local_seq_lens`; delegate model-wrapper attribute lookup to
the original model so DFlash context-KV callbacks remain accessible. |
|
[`vllm_ascend/worker/v2/input_batch.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/input_batch.py)
| [vLLM #58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture. | Always retain
prompt-tail and graph-eligibility fields and forward dummy-batch
`max_query_len`/`is_padding`; remove obsolete 0.30 branches. |
|
[`vllm_ascend/worker/v2/model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/model_runner.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58542](https://github.com/vllm-project/vllm/pull/58542) adds
`max_seq_len_np` for PP sampled-token broadcast handling. Present in
release batch state; absent from pinned main.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) replaces the
legacy PCP helper with descriptor-based `partition_batch`, restores
auxiliary hidden states with sampling outputs, and renames the DCP
preparation helper.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent.<br><br>[vLLM
#54335](https://github.com/vllm-project/vllm/pull/54335) routes
fixed-token scoring through the same unpadded logits path as prompt
logprobs, which is incompatible with Ascend lmhead-TP collective row
layouts. | Use release-only kwargs for profiling/execute and MC2 dummy
execution; forward release-only `max_seq_len_np`. After PD request
reclassification, recompute `has_prefill`, decode-graph eligibility and
uniform token count. Accept `num_active_loras` in the common prepare
signature without adding FastPrefillHelper behavior. Use
descriptor-based PCP partitioning and restore auxiliary states before
replicated drafting. Extend the lmhead-TP guard to fixed-token scoring,
tolerating workers without `token_id_scores`. |
|
[`vllm_ascend/worker/v2/model_states/mamba_hybrid.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/model_states/mamba_hybrid.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400)
requires decode-like prompt tails to use decode-row Mamba metadata for
speculative rollback. | Build a local mask `is_prefilling_np &
~prefill_runs_as_decode_np` so prompt tails are decode rows; do not
mutate the batch's original prefill mask. |
|
[`vllm_ascend/worker/v2/pcp_manager.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/pcp_manager.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980)
replaces the legacy PCP helper with descriptor-based `partition_batch`,
restores auxiliary hidden states with sampling outputs, and renames the
DCP preparation helper. | Unify descriptor-based partitioning, including
CPP profile capture after #18622, and the `(batch, hidden, aux)`
sampling restore contract; restore and trim auxiliary states together
with hidden states to the unpadded global token extent. |
|
[`vllm_ascend/worker/v2/spec_decode/autoregressive/aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/spec_decode/autoregressive/aclgraph.py)
| [vLLM #58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture. | Always pass
`desc.max_query_len or desc.uniform_token_count` to autoregressive
capture. |
|
[`vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Always receive and forward
`precompute_context_kv` under the Ascend communicator/model-capture
wrappers. |

</details>

<details>
<summary>KV allocation and block tables (6 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/_310p/worker/v2/block_table.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/block_table.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist.<br><br>[vLLM
#56734](https://github.com/vllm-project/vllm/pull/56734) uses
`idx_mapping=-1` for dummy draft/padding requests and masks their
persistent block-table reads to avoid stale-row KV writes. | Unify the
constructor with `dcp_sharded`; skip negative request indices and retain
PAD slots in the CPU mapping path. Keep the existing CP=1 restriction
and persistent CPU/device buffers. |
|
[`vllm_ascend/models/glm5next/kv_cache.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/models/glm5next/kv_cache.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) adds
`prefill_end` to Mamba checkpoint allocation, including prompt-end
retention. Release has the new signature; pinned main has the old one. |
Accept `prefill_end` for call compatibility; keep one private Kpool tail
block per request. |
|
[`vllm_ascend/ops/triton/v2/block_table/compute_slot_mappings.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/triton/v2/block_table/compute_slot_mappings.py)
| [vLLM #56734](https://github.com/vllm-project/vllm/pull/56734) uses
`idx_mapping=-1` for dummy draft/padding requests and masks their
persistent block-table reads to avoid stale-row KV writes. | Unify the
slot-mapping kernel, mask block-table loads with `is_real_req`, and emit
PAD for dummy rows; retain Ascend block/window and address-calculation
behavior. |
|
[`vllm_ascend/patch/platform/patch_kv_cache_utils.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_kv_cache_utils.py)
| The pinned `_annotate_eagle_groups` contract uses
`use_trailing_layer_fallback`, replacing the DeepSeek-V4-specific
fallback keyword; the introducing PR was not independently identified.
Fixed contracts: [release:
kv_cache_utils.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/kv_cache_utils.py#L2170).
| Always pass `use_trailing_layer_fallback=True`; retain existing Ascend
cache grouping/annotation behavior. |
|
[`vllm_ascend/patch/platform/patch_mamba_manager.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_mamba_manager.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) adds
`prefill_end` to Mamba checkpoint allocation, including prompt-end
retention. Release has the new signature; pinned main has the old one. |
Accept `prefill_end`, forwarding it only to the release parent while
retaining the existing Ascend allocation logic. |
|
[`vllm_ascend/worker/v2/block_table.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/block_table.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist. | Use one
constructor with optional per-group `dcp_sharded` validation/forwarding;
retain Ascend int32 slot mappings. |

</details>

<details>
<summary>Schedulers and profiling (5 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/core/dyntra_lb_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/dyntra_lb_scheduler.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#58259](https://github.com/vllm-project/vllm/pull/58259) define the
upstream resumable-session queue/handoff lifecycle: stopping a turn can
re-enqueue buffered continuation input.<br><br>Both targets admit
against `max_num_active_reqs` and include parked streaming sessions in
occupied slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Use KV-holder-first queue selection/re-enqueueing, the common
blocked-request helper, deferred bookkeeping and active-slot admission
including parked streams. Preserve the main-only encoder exception.
Remove secondary stop cleanup so upstream can retain/re-enqueue
resumable continuations. |
|
[`vllm_ascend/core/recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/recompute_scheduler.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>Both targets admit against
`max_num_active_reqs` and include parked streaming sessions in occupied
slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Fold the legacy queues into the common KV-holder/deferred path, count
parked streams for active admission, and preserve the version-dependent
encoder condition. Remove the redundant remote-KV waiting debug log as a
local cleanup. |
|
[`vllm_ascend/core/scheduler_profiling_chunk.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/scheduler_profiling_chunk.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>Both targets admit against
`max_num_active_reqs` and include parked streaming sessions in occupied
slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Use the common blocked-request/queue lifecycle, active admission
including parked streams, and the version-dependent encoder budget
condition. |
|
[`vllm_ascend/patch/platform/patch_balance_schedule.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_balance_schedule.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses `_handle_blocked_waiting_request`. |
Fold six obsolete 0.30 queue branches and add the release/main encoder
budget condition. Document the shared `if not request_queue`
drained-queue guard. Retain baseline balancing, running-only DP
snapshots/admission accounting and connector-snapshot cleanup; complete
upstream schedule synchronization is outside this patch. |
|
[`vllm_ascend/profiling_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/profiling_config.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947)
replaces `skipped_waiting` with `kv_holding_waiting` and
`deferred_waiting`, prioritizes KV holders, and uses
`_handle_blocked_waiting_request`. | Retarget the profiling wrapper from
the old blocked-status promotion helper to
`_handle_blocked_waiting_request`. |

</details>

<details>
<summary>EPLB state and routing (2 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/distributed/eplb/eplb_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/distributed/eplb/eplb_state.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) changes
main's EPLB setup to update existing state and reuse its communicator.
Release still creates state from `(model, model_config, mapping)`. |
After the parent's `update_mapping`, refresh Ascend replica routing
tables; consistently resolve an unspecified NPU device index to the
current device. |
|
[`vllm_ascend/worker/v2/eplb.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/eplb.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) changes
main's EPLB setup to update existing state and reuse its communicator.
Release still creates state from `(model, model_config, mapping)`. |
Create `AscendEplbState` on release with the current policy/optional
expert arguments; call the main parent to update the existing state and
communicator. |

</details>

<details>
<summary>Models and MoE operators (6 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/models/kimi_k3.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/models/kimi_k3.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592)/[vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) use
`prefix_delta` and the three-value AttnRes layer contract instead of the
old prepared-input/deferred-MLP contract. | Remove old layer/model
contracts, propagate `prefix_delta` and return the three-value AttnRes
state; preserve Ascend fused operations, DSpark aux selection and SP/PP
transport/output boundaries. |
|
[`vllm_ascend/ops/fused_moe/gate_linear.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/fused_moe/gate_linear.py)
| [vLLM #58234](https://github.com/vllm-project/vllm/pull/58234) unifies
MoE gate layers under `GateLinear` with the current linear constructor
and replaces Step3.5's dedicated FP32 gate class. | Use the current
constructor parameters (`skip_bias_add`, `quant_config`, `return_bias`)
and retain BF16-to-FP32 gate/fallback semantics. CRLF-to-LF
normalization contributes to the large line diff. |
|
[`vllm_ascend/ops/fused_moe/router/grouped_topk_router.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/fused_moe/router/grouped_topk_router.py)
| [vLLM #58880](https://github.com/vllm-project/vllm/pull/58880) removes
`routed_scaling_factor` from routing-method classification, allowing
MiniMax classification with non-unit scaling. | Stop passing
`routed_scaling_factor` to classification; downstream routing-weight
scaling is retained. |
|
[`vllm_ascend/patch/__init__.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/__init__.py)
| The release target is 0.31.0; [vLLM
#56994](https://github.com/vllm-project/vllm/pull/56994) is context for
the retained GLM reasoning patch comment, not a new model capability in
this PR. | Update only the supported-version comment for the retained
GLM reasoning patch. |
|
[`vllm_ascend/patch/worker/patch_step3p5.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_step3p5.py)
| [vLLM #58234](https://github.com/vllm-project/vllm/pull/58234) unifies
MoE gate layers under `GateLinear` with the current linear constructor
and replaces Step3.5's dedicated FP32 gate class. | Always use
`GateLinear` with FP32 parameter/output types instead of the legacy
FP32ReplicatedLinear branch. |

</details>

<details>
<summary>Token scoring and Triton helpers (2 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/patch/worker/patch_triton.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_triton.py)
| [vLLM #58651](https://github.com/vllm-project/vllm/pull/58651) uses
`triton.next_power_of_2` in packed-QK RoPE constexpr evaluation; the
Ascend replacement must also satisfy the installed Triton
JIT/constexpr-function contract. | Use a constexpr-aware
`next_power_of_2` replacement; register with `triton.constexpr_function`
when available, otherwise unwrap `tl.constexpr.value` in the fallback. |
|
[`vllm_ascend/worker/v2/sample/logprob.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/sample/logprob.py)
| [vLLM #54335](https://github.com/vllm-project/vllm/pull/54335) adds
fixed-token prompt scoring and broadcasts candidate IDs with `expand`;
the token-ID row stride can be zero or non-contiguous. | Pass
`token_ids.stride(0)` into the Triton kernel and use it for row
addressing; support broadcast stride zero and strided candidate IDs. |

</details>

BalanceScheduler scope: this PR folds the old queue branches and adapts
encoder-only admission. Its baseline DP balancing, running-only
snapshot/accounting and connector-snapshot cleanup remain; complete
scheduler-body synchronization and a strict AST equivalence requirement
are deferred. The baseline drift guard may skip and does not prove
complete upstream equivalence.

### Does this PR introduce _any_ user-facing change?

The default release dependency becomes vLLM v0.31.0; the verified-main
pin remains unchanged. Fixed-token prompt scoring handles
broadcast/strided IDs correctly and reports an explicit error when used
with unsupported lmhead TP. Resumable Dyntra continuations retain
upstream stop/queue behavior, and PD prompt-tail graph/Mamba metadata
follow the supported upstream contracts.

### How was this patch tested?

#### Test changes organized by file

The table describes test intent and fixture changes; it does not claim
that every changed test was selected or executed on NPU hardware.

<details>
<summary>Unit, PR E2E and nightly test mapping (37 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_compute_token_logprobs.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_compute_token_logprobs.py)
| [vLLM #54335](https://github.com/vllm-project/vllm/pull/54335) | Add
NPU numerical comparisons for broadcast stride=0 and sliced stride=8
token IDs; outside the PR CI selector. |
|
[`tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_num_nans.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_num_nans.py)
| Release-version cleanup; no new upstream behavior. | Update the
default version label to 0.31.0; no algorithm change. |
|
[`tests/e2e/pull_request/four_card/test_kimi_k3.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/four_card/test_kimi_k3.py)
| [vLLM #54222](https://github.com/vllm-project/vllm/pull/54222) | Check
equality between P-worker `remote_prefill_cached_tokens` and the
response cache count; zero hits are valid for a new prompt. |
|
[`tests/e2e/pull_request/one_card/test_model_runner_v1_with_device.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/one_card/test_model_runner_v1_with_device.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Use the
common AuxOutput configuration object in V1 guard fixtures. |
|
[`tests/e2e/pull_request/one_card/test_thinking_budget.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/one_card/test_thinking_budget.py)
| [vLLM #56497](https://github.com/vllm-project/vllm/pull/56497) |
Construct `LogitsContext` with expanded mapping, input IDs, positions
and sequence bounds; call `apply(logits, ctx)`. |
|
[`tests/ut/_310p/test_model_runner_v2_310p.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/_310p/test_model_runner_v2_310p.py)
| [vLLM #56456](https://github.com/vllm-project/vllm/pull/56456), [vLLM
#56497](https://github.com/vllm-project/vllm/pull/56497) | Use the
current sampler request signature and pass the added prepare-input LoRA
argument in 310P fixtures. |
|
[`tests/ut/attention/test_mla_cp.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/attention/test_mla_cp.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Mock `get_dcp_world_size_and_rank` and
remove legacy DCP group fixture branching. |
|
[`tests/ut/core/test_circular_buffer.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_circular_buffer.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Pass `replay_boundaries=[tokens-1]` to the current cache-block API. |
|
[`tests/ut/core/test_dyntra_lb_recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_dyntra_lb_recompute_scheduler.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) | Use
the shared KV-holder/deferred queue interfaces in Dyntra/recompute
fixtures. |
|
[`tests/ut/core/test_dyntra_lb_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_dyntra_lb_scheduler.py)
| [vLLM #58259](https://github.com/vllm-project/vllm/pull/58259), [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) | Regress
synchronous/asynchronous resumable continuation handling for running,
paused and preempted requests, buffered/unbuffered input, and final
cleanup; update queue seams. |
|
[`tests/ut/core/test_profiling_chunk.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_profiling_chunk.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934), [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) | Update queue
fixtures/blocked-request helper and active-request capacity field. |
|
[`tests/ut/core/test_recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_recompute_scheduler.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) |
Remove legacy queue branching and use the shared blocked-request seam. |
|
[`tests/ut/core/test_scheduler_connector_block_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_scheduler_connector_block_state.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947), [vLLM
#59029](https://github.com/vllm-project/vllm/pull/59029) | Supply the
baseline `balance_queue` fixture; connector-snapshot cleanup itself
predates this change. |
|
[`tests/ut/distributed/eplb/test_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/distributed/eplb/test_state.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) |
Verify mapping updates refresh Ascend routing tables. |
|
[`tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) | Use
the shared queue lifecycle rather than version-specific skipped-waiting
fixtures. |
|
[`tests/ut/kv_offload/test_preempt_offload_connector.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/kv_offload/test_preempt_offload_connector.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Always provide prefix replay and request token-count fields in the
offload fixture. |
|
[`tests/ut/models/test_deepseek_v41_release_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_deepseek_v41_release_config.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Assert obsolete flattened multimodal-prefix flags are absent after
architecture conversion. |
|
[`tests/ut/models/test_glm5next_kv_cache.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_glm5next_kv_cache.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) | Pass
the new allocation argument while checking the private-tail block
policy. |
|
[`tests/ut/models/test_kimi_k3_adapter.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_kimi_k3_adapter.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592), [vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) | Update layer
signatures/three-value returns, auxiliary output expectations and
AST-extracted fixtures. |
|
[`tests/ut/models/test_kimi_k3_pp_sp.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_kimi_k3_pp_sp.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592), [vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) | Use the
common Kimi AttnRes contract in PP/SP checks. |
|
[`tests/ut/patch/platform/test_patch_balance_schedule.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_patch_balance_schedule.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947), [vLLM
#59029](https://github.com/vllm-project/vllm/pull/59029) | Use common
queue fixtures; add eight encoder/chunked/prompt-budget cases and
empty/fully deferred queue regressions with/without KV blocks. Correct
the structural guard assertion to `if not request_queue`. Keep the
baseline AST drift check, which can skip. |
|
[`tests/ut/patch/platform/test_patch_engram_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_patch_engram_config.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Expect shared-memory default resolution for this supported fixture
configuration; no universal shared-memory default is claimed. |
|
[`tests/ut/patch/platform/test_prefix_cache_cp_patches.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_prefix_cache_cp_patches.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) |
Supply an explicit `prefill_end` allocation boundary. |
|
[`tests/ut/spec_decode/test_eagle_proposer.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/spec_decode/test_eagle_proposer.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Use the current model-config multimodal
capability interface and remove obsolete skips/branches. |
|
[`tests/ut/spec_decode/test_mla_dspark.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/spec_decode/test_mla_dspark.py)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) |
Assert DFlash context-KV callback forwarding and the shared capture
signature. |
|
[`tests/ut/test_minimax_m3_kv_block_size.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/test_minimax_m3_kv_block_size.py)
| Release-version cleanup; no new upstream behavior. | Remove only an
unused version-helper import. |
|
[`tests/ut/test_platform.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/test_platform.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Use the
current AuxOutput configuration guard for both target versions. |
|
[`tests/ut/worker/test_attn_utils_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_attn_utils_v2.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Initialize `model_state.model_config`
instead of assigning the read-only length property. |
|
[`tests/ut/worker/test_dcp_speculator_metadata_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_dcp_speculator_metadata_v2.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Assert prefill metadata over the padded
request extent. |
|
[`tests/ut/worker/test_model_runner_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58542](https://github.com/vllm-project/vllm/pull/58542) adds
`max_seq_len_np` for PP sampled-token broadcast handling. Present in
release batch state; absent from pinned main.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) replaces the
legacy PCP helper with descriptor-based `partition_batch`, restores
auxiliary hidden states with sampling outputs, and renames the DCP
preparation helper.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent.<br><br>[vLLM
#54335](https://github.com/vllm-project/vllm/pull/54335) routes
fixed-token scoring through the same unpadded logits path as prompt
logprobs, which is incompatible with Ascend lmhead-TP collective row
layouts.<br><br>[vLLM
#58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Cover release/main kwargs and PP fields, PD
graph reclassification, PCP auxiliary restoration and lmhead scoring
guards; update model-state fixtures. |
|
[`tests/ut/worker/test_model_runner_v2_encoder_decoder.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2_encoder_decoder.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Update model-state length fixtures through
model configuration. |
|
[`tests/ut/worker/test_model_runner_v2_mamba.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2_mamba.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) |
Regress prompt-tail masks for FULL/NONE graph modes and zero/three draft
tokens; verify the original mask is unchanged. |
|
[`tests/ut/worker/test_pcp_manager_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_pcp_manager_v2.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Assert
descriptor-based partitioning and hidden/aux restore layout; update
AuxOutput fixture configuration. |
|
[`tests/ut/worker/test_v2_dummy_padding.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_v2_dummy_padding.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture.<br><br>[vLLM
#58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Use the model-config-backed state/dummy
descriptor contract and retain graph-eligibility metadata. |
|
[`tests/ut/worker/v2/test_aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_aclgraph.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980), [vLLM
#58275](https://github.com/vllm-project/vllm/pull/58275) | Update
capture descriptors and dummy-batch keyword expectations. |
|
[`tests/ut/worker/v2/test_eplb_controller.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_eplb_controller.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) | Cover
release state construction versus main in-place state/communicator
reuse. |
|
[`tests/ut/worker/v2/test_eplb_load_collection_phase.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_eplb_load_collection_phase.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) | Match
each target's EPLB setup signature in load-collection fixtures. |

</details>

#### Local A3 nightly validation (2026-10-15; frozen head `444e962`)

These four model runs used **`444e962b239c3a8fc56b9255d601818e6e028b9a`
+ vLLM 0.31.0 (`db9527a`)**, which is also the restored PR head; the
deferred connector hardening is not included. Prefill 138 + Decode 136,
16 NPUs per node; original image, weights, datasets, launch and
benchmark parameters were retained, with only the second-node address
mapped from 139 to 136. All four cases exited pytest 0 on both nodes
(one passed JUnit case per node). OTT is output token/s; TPOT/TTFT are
ms.

| Case | Performance requests | OTT / required minimum | TPOT / TTFT |
AIME2025 accuracy | Result |
| --- | --- | --- | --- | --- | --- |
| Kimi-K2.6 PD | 60/60 | 355.1593 / 337.024075 | 20.5 / 3268.2 | 90%,
within 93.33±10 | Performance + accuracy passed |
| DeepSeek-V4 Flash PD-prefix | Accuracy only | N/A | N/A | 90%, within
90±10 | Accuracy passed |
| GLM-5.1 W8A8C8 128K | 256/256 | 811.7645 / 282.105876 | 39.8 / 32665.6
| No accuracy item | Performance passed |
| MiniMax-M2.7 PD-prefix | 160/160 | 711.0518 / 698.497 | 34.8 / 17438.2
| 90%, within 93.33±10 | Performance + accuracy passed |

All performance requests above, and the valid controls below, were
checked for actual 1024-token outputs, not just success flags.

**Conditional controls:** historical throughput differences triggered
only the affected performance cases against the same PR base `6d1dd70`,
without this PR, + vLLM 0.30.0 (`ced6857`). Kimi: 355.1593 vs 359.8514
OTT (**-1.30%**); the earlier 7.27% loss was not reproduced in this
comparison. TPOT was 20.5 vs 19.7ms (+0.8ms/+4.06%), and average request
latency +3.48%; a single pair does not establish latency equivalence or
a stable regression. GLM: 811.7645 vs 813.3506 OTT (**-0.20%**), TPOT
39.8 vs 39.4ms. Kimi's original random request pacing affects aggregate
OTT. No alternating reruns or unaffected-model 0.30 controls were added.

Archived evidence:
`main2main-nightly-20261013/pr18229-update-444e962-20261015/`
(`FINAL_REPORT.md`, per-node logs/JUnit, raw AISBench outputs,
token-count audit, controls and diagnostic evidence). Both nodes were
released after testing.

#### Deferred follow-up: multi-group receive-failure reporting (not
included)

The request-level receive-failure hardening change has been removed from
this upgrade PR; the branch is restored to the nightly-tested head
`444e962`. The original four nightlies already passed on this head
**without** that fix, so it is not required for these normal-path
workloads to pass.

The fault-path issue remains real: if a multi-group receive actually
fails, the existing connector can report flat block IDs and trigger the
vLLM 0.31 scheduler guard, terminating Decode EngineCore. This is
handled separately in
[#18823](https://github.com/vllm-project/vllm-ascend/pull/18823),
retaining ordinary non-HMA block-level recovery semantics. The upgrade
PR does not claim fault isolation is fixed.

Development fault-injection results belong to the deferred connector
implementation, not this restored head. No new NPU run was performed
when restoring the exact previously tested code.

#### Historical validation for head `23c8b15`

- New [E2E
workflow](https://github.com/vllm-project/vllm-ascend/actions/runs/38562748688)
and [Docs link
check](https://github.com/vllm-project/vllm-ascend/actions/runs/38562748395)
were triggered after the rebase. Results are pending; previous-head CI
does not validate this rebased head.
- A targeted [comment
command](https://github.com/vllm-project/vllm-ascend/pull/18229#issuecomment-6168149194)
requests `test_deepseek_v4_mtp_full_decode_only` against both supported
upstream targets. The [command
workflow](https://github.com/vllm-project/vllm-ascend/actions/runs/38562831465)
is queued; its actual test results remain pending.
- Ruff check and format check passed for all 72 changed Python files;
Python compilation and diff checks passed. Source-extracted execution of
both real CPP routing regressions passed against the required partition
signatures of the exact main/release refs. This validates dispatch
contracts with lightweight dependency stubs and does not replace full
pytest or NPU execution.
- Existing source-extracted scheduler regressions passed on both version
lanes: eight budget scenarios, two queue paths and empty/fully deferred
queue regressions, including negative controls.
- Local full pytest/Torch/NPU and `bash format.sh ci` remain unavailable
in this Windows environment. They require CI validation.
- Previous head `9330488` passed pre-commit, Docs and both CPU UT lanes
(main 10782 passed / 114 skipped; release 10784 passed / 112 skipped).
Its initial NPU matrix passed 41/42 shards; the remaining main A3 shard
failed in unchanged upstream teardown with `psutil.NoSuchProcess`,
before the MTP golden acceptance assertion. The consequent gate failure
and old-head rerun are historical evidence, not a result for the current
head.

#### Coverage limits and historical evidence

The PR CI selector scans `tests/ut` and `tests/e2e/pull_request`; the
new broadcast/strided token-logprob numerical tests under
`tests/e2e/nightly` are outside that selection. A5, standalone
upstream-worker and coverage-upload jobs were skipped in the inspected
run. Skips are not coverage. No dedicated packed-QK RoPE or V1
profiling-randomization standalone UT is added by this final diff.

Previous head `15f8a3d` passed
[E2E](https://github.com/vllm-project/vllm-ascend/actions/runs/38511018361)
and
[Docs](https://github.com/vllm-project/vllm-ascend/actions/runs/38511018193),
including 42 NPU jobs. Its PR-recorded CPU counts were 10574 passed /
113 skipped for verified main and 10576 passed / 111 skipped for
release, with no failures. Those counts belong to that historical head
and are not asserted as current-head counts.

- vLLM main:
https://github.com/vllm-project/vllm/commit/c4df37dfcc7f72ca41cd43801a468526ecf99a2b

---------

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Co-authored-by: shenzhao <shenzhao9@huawei.com>
tangdafu pushed a commit to tangdafu/vllm-ascend that referenced this pull request Oct 20, 2026
…ct#18622)

### What this PR does / why we need it?

CPP startup profiling calls the model runner dummy path with one
synthetic request. With PCP enabled, the generic V2 dummy batch is
initialized with decode-only attention state and the PCP dummy fast path
bypasses `partition_batch()`. A large CPP profiling sample can therefore
enter the PCP decode O-projection communication path without being
partitioned, where its token rows exceed the decode buffer capacity.

This PR:

- carries an explicit CPP-profile marker through the V2 model runner and
input batch;
- builds CPP dummy inputs with fresh-prefill metadata and
`PrefillNoCache` attention state;
- sends CPP profiling dummy batches through PCP `partition_batch()`
while preserving ordinary capture/runtime dummy behavior;
- skips the speculative drafter only for CPP profiling, matching the
existing V1 behavior; and
- adds unit coverage for CPP dummy construction, state restoration, and
PCP partitioning.

### Does this PR introduce _any_ user-facing change?

Yes. CPP startup profiling now works with PCP-enabled V2 deployments
instead of routing large profiling dummy batches through the decode-only
PCP path. There is no CLI or configuration API change.

### How was this patch tested?

Unit tests:

```bash
python -m pytest -q \
  tests/ut/worker/test_v2_dummy_padding.py \
  tests/ut/worker/test_pcp_manager_v2.py \
  tests/ut/worker/test_model_runner_v2.py \
  tests/ut/worker/test_worker_v2.py
```

Result: `240 passed, 14 warnings`.

End-to-end validation used GLM-5.2 W4A8 with PP=2, TP=2, PCP=4, EP
enabled, MTP=1, eager mode, and `max_num_batched_tokens=20480`:

- CPP collected all 64 startup samples and reported `Profiling completed
successfully`;
- the service reached `/health` HTTP 200 without the previous
decode-capacity `ValueError`;
- AISBench warmup: 5/5 requests succeeded;
- fixed-length prefill (65,536 input tokens, concurrency 2): 24/24
succeeded; and
- variable-length prefill (40,960-81,920 input tokens, concurrency 2):
24/24 succeeded.

A CPP-disabled run of the same service and three workloads also
completed with zero failed requests, covering the non-CPP path.

- vLLM main:
vllm-project/vllm@c4df37d

---------

Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
tangdafu pushed a commit to tangdafu/vllm-ascend that referenced this pull request Oct 20, 2026
…tibility (vllm-project#18229)

### What this PR does / why we need it?

Upgrade the release dependency from vLLM v0.30.0 to
[v0.31.0](https://github.com/vllm-project/vllm/commit/db9527a46873454610df6dbedf79a36d6bf1a7f6)
while keeping the independently supported verified-main target at
[c4df37d](https://github.com/vllm-project/vllm/commit/c4df37dfcc7f72ca41cd43801a468526ecf99a2b).
Rebase on latest Ascend main `c2382c6`, preserving the CPP profiling
changes from #18622. The file mapping below describes the diff for
`23c8b15` against `c2382c6`.

The two targets have different APIs despite both being supported: retain
version-dependent forwarding for profiling randomization, PP batch
lengths, Mamba allocation, EPLB setup and encoder-only prefill
admission. Remove obsolete 0.30 branches only where both targets now
share the contract.

| Contract | Verified main `c4df37d` | Release v0.31.0 `db9527a` |
| --- | --- | --- |
| Profiling | Parent calls omit `randomize_inputs` | Forward the flag
through V1/V2/310P and MC2 |
| PP batch state | No `max_seq_len_np` | Preserve the field in
`AscendInputBatch` |
| Mamba allocation | Parent has no `prefill_end` | Forward checkpoint
boundary |
| EPLB setup | Update existing state/communicator | Construct state from
model and mapping |
| Non-chunked prefill | Keep encoder-only budget exception | Keep
release budget rejection |

#### Changes organized by downstream file

Upstream links identify the reason or contract being adapted. For
existing main behavior that becomes common to both targets, the change
is removal of the old release branch, not a new port of the complete
upstream implementation. File links are pinned to this PR head; [the
complete fixed
diff](https://github.com/vllm-project/vllm-ascend/compare/c2382c67aa6be12f1c822733cd47d021f61b0b23...23c8b15c2709978463490b0e8531bf5f9f27b9c1)
shows the exact edits.

<details>
<summary>Dependency markers, images and documentation (13
files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`.github/vllm-release-tag.commit`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/.github/vllm-release-tag.commit)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Advance the release marker
to `v0.31.0`; leave the verified-main marker at `c4df37d`. |
|
[`Dockerfile`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.310p`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.310p)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.310p.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.310p.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a3`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a3)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a3.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a3.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a5`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a5)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.a5.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.a5.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`Dockerfile.openEuler`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/Dockerfile.openEuler)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Set the release `VLLM_TAG`
default to `v0.31.0`; existing built images are not changed by this
default. |
|
[`README.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/README.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Update the release CI
support version to 0.31.0. |
|
[`README.zh.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/README.zh.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Update the Chinese release
CI support version to 0.31.0. |
|
[`docs/source/tutorials/models/DeepSeek-V4.1-Flash.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/docs/source/tutorials/models/DeepSeek-V4.1-Flash.md)
| Release target advances to
[v0.31.0](https://github.com/vllm-project/vllm/releases/tag/v0.31.0);
verified main remains pinned independently. | Use separate release and
verified-main marker commands for the two build targets. |
|
[`vllm_ascend/ops/triton/docs/v2/spec_decode/prepare_dflash_inputs.md`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/triton/docs/v2/spec_decode/prepare_dflash_inputs.md)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Update the documented
DFlash ABI version to 0.31.0; no new kernel behavior is introduced by
this document change. |

</details>

<details>
<summary>Model runners, graphs and platform integration (14
files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/_310p/model_runner_310p.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/model_runner_310p.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls. | Forward the profiling randomization flag through the 310P V1
override to the NPU V1 runner. |
|
[`vllm_ascend/_310p/worker/v2/model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/model_runner.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent. | Forward release-only
randomization; accept `num_active_loras` in the common prepare
signature, use the shared PCP/input-batch contract and compute complete
prompt-tail/decode-graph metadata in CPU input preparation. |
|
[`vllm_ascend/_310p/worker/v2/sampler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/sampler.py)
| [vLLM #56497](https://github.com/vllm-project/vllm/pull/56497)
introduces V2 `LogitsContext` and custom logits-processor lifecycle;
`Sampler.add_request` no longer takes `prompt_len`. | Adopt
`add_request(req_idx, sampling_params)` and remove the legacy
prompt-length argument; retain the 310P CPU generator/sampling
implementation. |
|
[`vllm_ascend/attention/attention_v1.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/attention/attention_v1.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility. | Remove the 0.30 condition around
V2 speculative-padding handling while retaining actual prefill/decode
metadata semantics. |
|
[`vllm_ascend/patch/worker/patch_v2/patch_model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_v2/patch_model_runner.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist.<br><br>[vLLM
#45635](https://github.com/vllm-project/vllm/pull/45635) moves
routed-expert output to `AuxOutputConfig`/the AuxOutput connector; [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) removes the
legacy runner initialization keyword. | Read `dcp_sharded` from cache
specs and forward it to block tables; initialize the AuxOutput connector
from `aux_output_config.enabled`; drop the legacy `attn_cg_support`
keyword. |
|
[`vllm_ascend/platform.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/platform.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635) moves
routed-expert output to `AuxOutputConfig`/the AuxOutput connector; [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) removes the
legacy runner initialization keyword. | Apply the existing V1 AuxOutput
configuration guard to both targets, removing the old 0.30 early return.
|
|
[`vllm_ascend/worker/model_runner_v1.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/model_runner_v1.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls. | Accept `randomize_inputs` in profiling/dummy execution and
enter `maybe_randomize_inputs` inside forward context when requested;
preserve the Ascend execution path. |
|
[`vllm_ascend/worker/v2/aclgraph_utils.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/aclgraph_utils.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980)
replaces the legacy PCP helper with descriptor-based `partition_batch`,
restores auxiliary hidden states with sampling outputs, and renames the
DCP preparation helper.<br><br>[vLLM
#57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Use
`prepare_dcp_local_seq_lens`; delegate model-wrapper attribute lookup to
the original model so DFlash context-KV callbacks remain accessible. |
|
[`vllm_ascend/worker/v2/input_batch.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/input_batch.py)
| [vLLM #58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture. | Always retain
prompt-tail and graph-eligibility fields and forward dummy-batch
`max_query_len`/`is_padding`; remove obsolete 0.30 branches. |
|
[`vllm_ascend/worker/v2/model_runner.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/model_runner.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58542](https://github.com/vllm-project/vllm/pull/58542) adds
`max_seq_len_np` for PP sampled-token broadcast handling. Present in
release batch state; absent from pinned main.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) replaces the
legacy PCP helper with descriptor-based `partition_batch`, restores
auxiliary hidden states with sampling outputs, and renames the DCP
preparation helper.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent.<br><br>[vLLM
#54335](https://github.com/vllm-project/vllm/pull/54335) routes
fixed-token scoring through the same unpadded logits path as prompt
logprobs, which is incompatible with Ascend lmhead-TP collective row
layouts. | Use release-only kwargs for profiling/execute and MC2 dummy
execution; forward release-only `max_seq_len_np`. After PD request
reclassification, recompute `has_prefill`, decode-graph eligibility and
uniform token count. Accept `num_active_loras` in the common prepare
signature without adding FastPrefillHelper behavior. Use
descriptor-based PCP partitioning and restore auxiliary states before
replicated drafting. Extend the lmhead-TP guard to fixed-token scoring,
tolerating workers without `token_id_scores`. |
|
[`vllm_ascend/worker/v2/model_states/mamba_hybrid.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/model_states/mamba_hybrid.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400)
requires decode-like prompt tails to use decode-row Mamba metadata for
speculative rollback. | Build a local mask `is_prefilling_np &
~prefill_runs_as_decode_np` so prompt tails are decode rows; do not
mutate the batch's original prefill mask. |
|
[`vllm_ascend/worker/v2/pcp_manager.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/pcp_manager.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980)
replaces the legacy PCP helper with descriptor-based `partition_batch`,
restores auxiliary hidden states with sampling outputs, and renames the
DCP preparation helper. | Unify descriptor-based partitioning, including
CPP profile capture after #18622, and the `(batch, hidden, aux)`
sampling restore contract; restore and trim auxiliary states together
with hidden states to the unpadded global token extent. |
|
[`vllm_ascend/worker/v2/spec_decode/autoregressive/aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/spec_decode/autoregressive/aclgraph.py)
| [vLLM #58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture. | Always pass
`desc.max_query_len or desc.uniform_token_count` to autoregressive
capture. |
|
[`vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) passes
`precompute_context_kv` into DFlash FULL-graph capture; wrapped draft
models must expose the underlying callback. | Always receive and forward
`precompute_context_kv` under the Ascend communicator/model-capture
wrappers. |

</details>

<details>
<summary>KV allocation and block tables (6 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/_310p/worker/v2/block_table.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/_310p/worker/v2/block_table.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist.<br><br>[vLLM
#56734](https://github.com/vllm-project/vllm/pull/56734) uses
`idx_mapping=-1` for dummy draft/padding requests and masks their
persistent block-table reads to avoid stale-row KV writes. | Unify the
constructor with `dcp_sharded`; skip negative request indices and retain
PAD slots in the CPU mapping path. Keep the existing CP=1 restriction
and persistent CPU/device buffers. |
|
[`vllm_ascend/models/glm5next/kv_cache.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/models/glm5next/kv_cache.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) adds
`prefill_end` to Mamba checkpoint allocation, including prompt-end
retention. Release has the new signature; pinned main has the old one. |
Accept `prefill_end` for call compatibility; keep one private Kpool tail
block per request. |
|
[`vllm_ascend/ops/triton/v2/block_table/compute_slot_mappings.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/triton/v2/block_table/compute_slot_mappings.py)
| [vLLM #56734](https://github.com/vllm-project/vllm/pull/56734) uses
`idx_mapping=-1` for dummy draft/padding requests and masks their
persistent block-table reads to avoid stale-row KV writes. | Unify the
slot-mapping kernel, mask block-table loads with `is_real_req`, and emit
PAD for dummy rows; retain Ascend block/window and address-calculation
behavior. |
|
[`vllm_ascend/patch/platform/patch_kv_cache_utils.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_kv_cache_utils.py)
| The pinned `_annotate_eagle_groups` contract uses
`use_trailing_layer_fallback`, replacing the DeepSeek-V4-specific
fallback keyword; the introducing PR was not independently identified.
Fixed contracts: [release:
kv_cache_utils.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/kv_cache_utils.py#L2170).
| Always pass `use_trailing_layer_fallback=True`; retain existing Ascend
cache grouping/annotation behavior. |
|
[`vllm_ascend/patch/platform/patch_mamba_manager.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_mamba_manager.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) adds
`prefill_end` to Mamba checkpoint allocation, including prompt-end
retention. Release has the new signature; pinned main has the old one. |
Accept `prefill_end`, forwarding it only to the release parent while
retaining the existing Ascend allocation logic. |
|
[`vllm_ascend/worker/v2/block_table.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/block_table.py)
| [vLLM #56723](https://github.com/vllm-project/vllm/pull/56723) adds
`dcp_sharded` to distinguish sharded attention KV from replicated
Mamba/GDN state when target DCP and DCP=1 draft coexist. | Use one
constructor with optional per-group `dcp_sharded` validation/forwarding;
retain Ascend int32 slot mappings. |

</details>

<details>
<summary>Schedulers and profiling (5 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/core/dyntra_lb_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/dyntra_lb_scheduler.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#58259](https://github.com/vllm-project/vllm/pull/58259) define the
upstream resumable-session queue/handoff lifecycle: stopping a turn can
re-enqueue buffered continuation input.<br><br>Both targets admit
against `max_num_active_reqs` and include parked streaming sessions in
occupied slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Use KV-holder-first queue selection/re-enqueueing, the common
blocked-request helper, deferred bookkeeping and active-slot admission
including parked streams. Preserve the main-only encoder exception.
Remove secondary stop cleanup so upstream can retain/re-enqueue
resumable continuations. |
|
[`vllm_ascend/core/recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/recompute_scheduler.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>Both targets admit against
`max_num_active_reqs` and include parked streaming sessions in occupied
slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Fold the legacy queues into the common KV-holder/deferred path, count
parked streams for active admission, and preserve the version-dependent
encoder condition. Remove the redundant remote-KV waiting debug log as a
local cleanup. |
|
[`vllm_ascend/core/scheduler_profiling_chunk.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/core/scheduler_profiling_chunk.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses
`_handle_blocked_waiting_request`.<br><br>Both targets admit against
`max_num_active_reqs` and include parked streaming sessions in occupied
slots; related queue/Elastic-EP changes are [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) and [vLLM
#53934](https://github.com/vllm-project/vllm/pull/53934). Fixed
contracts: [release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L127),
[release:
scheduler.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/sched/scheduler.py#L892).
| Use the common blocked-request/queue lifecycle, active admission
including parked streams, and the version-dependent encoder budget
condition. |
|
[`vllm_ascend/patch/platform/patch_balance_schedule.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/platform/patch_balance_schedule.py)
| [vLLM #59029](https://github.com/vllm-project/vllm/pull/59029) gives
main an encoder-only exception to the non-chunked prefill budget check;
release keeps the budget rejection condition.<br><br>[vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) replaces
`skipped_waiting` with `kv_holding_waiting` and `deferred_waiting`,
prioritizes KV holders, and uses `_handle_blocked_waiting_request`. |
Fold six obsolete 0.30 queue branches and add the release/main encoder
budget condition. Document the shared `if not request_queue`
drained-queue guard. Retain baseline balancing, running-only DP
snapshots/admission accounting and connector-snapshot cleanup; complete
upstream schedule synchronization is outside this patch. |
|
[`vllm_ascend/profiling_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/profiling_config.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947)
replaces `skipped_waiting` with `kv_holding_waiting` and
`deferred_waiting`, prioritizes KV holders, and uses
`_handle_blocked_waiting_request`. | Retarget the profiling wrapper from
the old blocked-status promotion helper to
`_handle_blocked_waiting_request`. |

</details>

<details>
<summary>EPLB state and routing (2 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/distributed/eplb/eplb_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/distributed/eplb/eplb_state.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) changes
main's EPLB setup to update existing state and reuse its communicator.
Release still creates state from `(model, model_config, mapping)`. |
After the parent's `update_mapping`, refresh Ascend replica routing
tables; consistently resolve an unspecified NPU device index to the
current device. |
|
[`vllm_ascend/worker/v2/eplb.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/eplb.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) changes
main's EPLB setup to update existing state and reuse its communicator.
Release still creates state from `(model, model_config, mapping)`. |
Create `AscendEplbState` on release with the current policy/optional
expert arguments; call the main parent to update the existing state and
communicator. |

</details>

<details>
<summary>Models and MoE operators (6 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/models/kimi_k3.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/models/kimi_k3.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592)/[vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) use
`prefix_delta` and the three-value AttnRes layer contract instead of the
old prepared-input/deferred-MLP contract. | Remove old layer/model
contracts, propagate `prefix_delta` and return the three-value AttnRes
state; preserve Ascend fused operations, DSpark aux selection and SP/PP
transport/output boundaries. |
|
[`vllm_ascend/ops/fused_moe/gate_linear.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/fused_moe/gate_linear.py)
| [vLLM #58234](https://github.com/vllm-project/vllm/pull/58234) unifies
MoE gate layers under `GateLinear` with the current linear constructor
and replaces Step3.5's dedicated FP32 gate class. | Use the current
constructor parameters (`skip_bias_add`, `quant_config`, `return_bias`)
and retain BF16-to-FP32 gate/fallback semantics. CRLF-to-LF
normalization contributes to the large line diff. |
|
[`vllm_ascend/ops/fused_moe/router/grouped_topk_router.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/ops/fused_moe/router/grouped_topk_router.py)
| [vLLM #58880](https://github.com/vllm-project/vllm/pull/58880) removes
`routed_scaling_factor` from routing-method classification, allowing
MiniMax classification with non-unit scaling. | Stop passing
`routed_scaling_factor` to classification; downstream routing-weight
scaling is retained. |
|
[`vllm_ascend/patch/__init__.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/__init__.py)
| The release target is 0.31.0; [vLLM
#56994](https://github.com/vllm-project/vllm/pull/56994) is context for
the retained GLM reasoning patch comment, not a new model capability in
this PR. | Update only the supported-version comment for the retained
GLM reasoning patch. |
|
[`vllm_ascend/patch/worker/patch_step3p5.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_step3p5.py)
| [vLLM #58234](https://github.com/vllm-project/vllm/pull/58234) unifies
MoE gate layers under `GateLinear` with the current linear constructor
and replaces Step3.5's dedicated FP32 gate class. | Always use
`GateLinear` with FP32 parameter/output types instead of the legacy
FP32ReplicatedLinear branch. |

</details>

<details>
<summary>Token scoring and Triton helpers (2 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`vllm_ascend/patch/worker/patch_triton.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/patch/worker/patch_triton.py)
| [vLLM #58651](https://github.com/vllm-project/vllm/pull/58651) uses
`triton.next_power_of_2` in packed-QK RoPE constexpr evaluation; the
Ascend replacement must also satisfy the installed Triton
JIT/constexpr-function contract. | Use a constexpr-aware
`next_power_of_2` replacement; register with `triton.constexpr_function`
when available, otherwise unwrap `tl.constexpr.value` in the fallback. |
|
[`vllm_ascend/worker/v2/sample/logprob.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/vllm_ascend/worker/v2/sample/logprob.py)
| [vLLM #54335](https://github.com/vllm-project/vllm/pull/54335) adds
fixed-token prompt scoring and broadcasts candidate IDs with `expand`;
the token-ID row stride can be zero or non-contiguous. | Pass
`token_ids.stride(0)` into the Triton kernel and use it for row
addressing; support broadcast stride zero and strided candidate IDs. |

</details>

BalanceScheduler scope: this PR folds the old queue branches and adapts
encoder-only admission. Its baseline DP balancing, running-only
snapshot/accounting and connector-snapshot cleanup remain; complete
scheduler-body synchronization and a strict AST equivalence requirement
are deferred. The baseline drift guard may skip and does not prove
complete upstream equivalence.

### Does this PR introduce _any_ user-facing change?

The default release dependency becomes vLLM v0.31.0; the verified-main
pin remains unchanged. Fixed-token prompt scoring handles
broadcast/strided IDs correctly and reports an explicit error when used
with unsupported lmhead TP. Resumable Dyntra continuations retain
upstream stop/queue behavior, and PD prompt-tail graph/Mamba metadata
follow the supported upstream contracts.

### How was this patch tested?

#### Test changes organized by file

The table describes test intent and fixture changes; it does not claim
that every changed test was selected or executed on NPU hardware.

<details>
<summary>Unit, PR E2E and nightly test mapping (37 files)</summary>

| Downstream file | Upstream change / contract | Ascend adaptation |
| --- | --- | --- |
|
[`tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_compute_token_logprobs.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_compute_token_logprobs.py)
| [vLLM #54335](https://github.com/vllm-project/vllm/pull/54335) | Add
NPU numerical comparisons for broadcast stride=0 and sliced stride=8
token IDs; outside the PR CI selector. |
|
[`tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_num_nans.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/nightly/single_node/ops/singlecard_ops/triton/test_num_nans.py)
| Release-version cleanup; no new upstream behavior. | Update the
default version label to 0.31.0; no algorithm change. |
|
[`tests/e2e/pull_request/four_card/test_kimi_k3.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/four_card/test_kimi_k3.py)
| [vLLM #54222](https://github.com/vllm-project/vllm/pull/54222) | Check
equality between P-worker `remote_prefill_cached_tokens` and the
response cache count; zero hits are valid for a new prompt. |
|
[`tests/e2e/pull_request/one_card/test_model_runner_v1_with_device.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/one_card/test_model_runner_v1_with_device.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Use the
common AuxOutput configuration object in V1 guard fixtures. |
|
[`tests/e2e/pull_request/one_card/test_thinking_budget.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/e2e/pull_request/one_card/test_thinking_budget.py)
| [vLLM #56497](https://github.com/vllm-project/vllm/pull/56497) |
Construct `LogitsContext` with expanded mapping, input IDs, positions
and sequence bounds; call `apply(logits, ctx)`. |
|
[`tests/ut/_310p/test_model_runner_v2_310p.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/_310p/test_model_runner_v2_310p.py)
| [vLLM #56456](https://github.com/vllm-project/vllm/pull/56456), [vLLM
#56497](https://github.com/vllm-project/vllm/pull/56497) | Use the
current sampler request signature and pass the added prepare-input LoRA
argument in 310P fixtures. |
|
[`tests/ut/attention/test_mla_cp.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/attention/test_mla_cp.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Mock `get_dcp_world_size_and_rank` and
remove legacy DCP group fixture branching. |
|
[`tests/ut/core/test_circular_buffer.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_circular_buffer.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Pass `replay_boundaries=[tokens-1]` to the current cache-block API. |
|
[`tests/ut/core/test_dyntra_lb_recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_dyntra_lb_recompute_scheduler.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) | Use
the shared KV-holder/deferred queue interfaces in Dyntra/recompute
fixtures. |
|
[`tests/ut/core/test_dyntra_lb_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_dyntra_lb_scheduler.py)
| [vLLM #58259](https://github.com/vllm-project/vllm/pull/58259), [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) | Regress
synchronous/asynchronous resumable continuation handling for running,
paused and preempted requests, buffered/unbuffered input, and final
cleanup; update queue seams. |
|
[`tests/ut/core/test_profiling_chunk.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_profiling_chunk.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934), [vLLM
#58947](https://github.com/vllm-project/vllm/pull/58947) | Update queue
fixtures/blocked-request helper and active-request capacity field. |
|
[`tests/ut/core/test_recompute_scheduler.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_recompute_scheduler.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) |
Remove legacy queue branching and use the shared blocked-request seam. |
|
[`tests/ut/core/test_scheduler_connector_block_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/core/test_scheduler_connector_block_state.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947), [vLLM
#59029](https://github.com/vllm-project/vllm/pull/59029) | Supply the
baseline `balance_queue` fixture; connector-snapshot cleanup itself
predates this change. |
|
[`tests/ut/distributed/eplb/test_state.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/distributed/eplb/test_state.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) |
Verify mapping updates refresh Ascend routing tables. |
|
[`tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947) | Use
the shared queue lifecycle rather than version-specific skipped-waiting
fixtures. |
|
[`tests/ut/kv_offload/test_preempt_offload_connector.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/kv_offload/test_preempt_offload_connector.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Always provide prefix replay and request token-count fields in the
offload fixture. |
|
[`tests/ut/models/test_deepseek_v41_release_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_deepseek_v41_release_config.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Assert obsolete flattened multimodal-prefix flags are absent after
architecture conversion. |
|
[`tests/ut/models/test_glm5next_kv_cache.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_glm5next_kv_cache.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) | Pass
the new allocation argument while checking the private-tail block
policy. |
|
[`tests/ut/models/test_kimi_k3_adapter.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_kimi_k3_adapter.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592), [vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) | Update layer
signatures/three-value returns, auxiliary output expectations and
AST-extracted fixtures. |
|
[`tests/ut/models/test_kimi_k3_pp_sp.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/models/test_kimi_k3_pp_sp.py)
| [vLLM #50592](https://github.com/vllm-project/vllm/pull/50592), [vLLM
#50593](https://github.com/vllm-project/vllm/pull/50593) | Use the
common Kimi AttnRes contract in PP/SP checks. |
|
[`tests/ut/patch/platform/test_patch_balance_schedule.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_patch_balance_schedule.py)
| [vLLM #58947](https://github.com/vllm-project/vllm/pull/58947), [vLLM
#59029](https://github.com/vllm-project/vllm/pull/59029) | Use common
queue fixtures; add eight encoder/chunked/prompt-budget cases and
empty/fully deferred queue regressions with/without KV blocks. Correct
the structural guard assertion to `if not request_queue`. Keep the
baseline AST drift check, which can skip. |
|
[`tests/ut/patch/platform/test_patch_engram_config.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_patch_engram_config.py)
| Pinned cache allocation requires replay boundaries ([vLLM
#58368](https://github.com/vllm-project/vllm/pull/58368)); DeepSeek-V4.1
architecture metadata and Engram configuration ([vLLM
#56214](https://github.com/vllm-project/vllm/pull/56214)) use their
current configuration contracts. Individual configuration migrations are
linked to fixed source where not precisely attributed. Fixed contracts:
[release:
single_type_kv_cache_manager.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/v1/core/single_type_kv_cache_manager.py#L482),
[release:
model_arch.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/model_arch.py#L59),
[release:
engram.py](https://github.com/vllm-project/vllm/blob/db9527a46873454610df6dbedf79a36d6bf1a7f6/vllm/config/engram.py#L89).
| Expect shared-memory default resolution for this supported fixture
configuration; no universal shared-memory default is claimed. |
|
[`tests/ut/patch/platform/test_prefix_cache_cp_patches.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/patch/platform/test_prefix_cache_cp_patches.py)
| [vLLM #59175](https://github.com/vllm-project/vllm/pull/59175) |
Supply an explicit `prefill_end` allocation boundary. |
|
[`tests/ut/spec_decode/test_eagle_proposer.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/spec_decode/test_eagle_proposer.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Use the current model-config multimodal
capability interface and remove obsolete skips/branches. |
|
[`tests/ut/spec_decode/test_mla_dspark.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/spec_decode/test_mla_dspark.py)
| [vLLM #57632](https://github.com/vllm-project/vllm/pull/57632) |
Assert DFlash context-KV callback forwarding and the shared capture
signature. |
|
[`tests/ut/test_minimax_m3_kv_block_size.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/test_minimax_m3_kv_block_size.py)
| Release-version cleanup; no new upstream behavior. | Remove only an
unused version-helper import. |
|
[`tests/ut/test_platform.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/test_platform.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Use the
current AuxOutput configuration guard for both target versions. |
|
[`tests/ut/worker/test_attn_utils_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_attn_utils_v2.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Initialize `model_state.model_config`
instead of assigning the read-only length property. |
|
[`tests/ut/worker/test_dcp_speculator_metadata_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_dcp_speculator_metadata_v2.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Assert prefill metadata over the padded
request extent. |
|
[`tests/ut/worker/test_model_runner_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2.py)
| [vLLM #58411](https://github.com/vllm-project/vllm/pull/58411) adds
`randomize_inputs` for memory profiling to avoid all-zero MoE input
concentration. Present in release; absent from the pinned-main parent
calls.<br><br>[vLLM
#58542](https://github.com/vllm-project/vllm/pull/58542) adds
`max_seq_len_np` for PP sampled-token broadcast handling. Present in
release batch state; absent from pinned main.<br><br>[vLLM
#58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) replaces the
legacy PCP helper with descriptor-based `partition_batch`, restores
auxiliary hidden states with sampling outputs, and renames the DCP
preparation helper.<br><br>[vLLM
#56456](https://github.com/vllm-project/vllm/pull/56456) adds trailing
`num_active_loras` to `prepare_inputs`, keeping dispatch and
fast-prefill graph/padding selection consistent.<br><br>[vLLM
#54335](https://github.com/vllm-project/vllm/pull/54335) routes
fixed-token scoring through the same unpadded logits path as prompt
logprobs, which is incompatible with Ascend lmhead-TP collective row
layouts.<br><br>[vLLM
#58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Cover release/main kwargs and PP fields, PD
graph reclassification, PCP auxiliary restoration and lmhead scoring
guards; update model-state fixtures. |
|
[`tests/ut/worker/test_model_runner_v2_encoder_decoder.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2_encoder_decoder.py)
| [vLLM #58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Update model-state length fixtures through
model configuration. |
|
[`tests/ut/worker/test_model_runner_v2_mamba.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_model_runner_v2_mamba.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) |
Regress prompt-tail masks for FULL/NONE graph modes and zero/three draft
tokens; verify the original mask is unchanged. |
|
[`tests/ut/worker/test_pcp_manager_v2.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_pcp_manager_v2.py)
| [vLLM #45635](https://github.com/vllm-project/vllm/pull/45635), [vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) | Assert
descriptor-based partitioning and hidden/aux restore layout; update
AuxOutput fixture configuration. |
|
[`tests/ut/worker/test_v2_dummy_padding.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/test_v2_dummy_padding.py)
| [vLLM #58400](https://github.com/vllm-project/vllm/pull/58400) adds
`prefill_runs_as_decode_np` and `decode_graph_eligible` for single-token
prompt tails with existing context; `has_prefill` alone no longer
determines FULL-decode eligibility.<br><br>[vLLM
#58275](https://github.com/vllm-project/vllm/pull/58275)/[vLLM
#57980](https://github.com/vllm-project/vllm/pull/57980) expose
`max_query_len`/`is_padding` on dummy batches and an explicit
query-length bound for autoregressive graph capture.<br><br>[vLLM
#58149](https://github.com/vllm-project/vllm/pull/58149) makes
`ModelState.max_model_len` a model-config-backed property; [vLLM
#57913](https://github.com/vllm-project/vllm/pull/57913) moves
multimodal capability to `ModelConfig`; [vLLM
#56723](https://github.com/vllm-project/vllm/pull/56723) updates DCP
state/metadata contracts. | Use the model-config-backed state/dummy
descriptor contract and retain graph-eligibility metadata. |
|
[`tests/ut/worker/v2/test_aclgraph.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_aclgraph.py)
| [vLLM #57980](https://github.com/vllm-project/vllm/pull/57980), [vLLM
#58275](https://github.com/vllm-project/vllm/pull/58275) | Update
capture descriptors and dummy-batch keyword expectations. |
|
[`tests/ut/worker/v2/test_eplb_controller.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_eplb_controller.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) | Cover
release state construction versus main in-place state/communicator
reuse. |
|
[`tests/ut/worker/v2/test_eplb_load_collection_phase.py`](https://github.com/vllm-project/vllm-ascend/blob/23c8b15c2709978463490b0e8531bf5f9f27b9c1/tests/ut/worker/v2/test_eplb_load_collection_phase.py)
| [vLLM #53934](https://github.com/vllm-project/vllm/pull/53934) | Match
each target's EPLB setup signature in load-collection fixtures. |

</details>

#### Local A3 nightly validation (2026-10-15; frozen head `444e962`)

These four model runs used **`444e962b239c3a8fc56b9255d601818e6e028b9a`
+ vLLM 0.31.0 (`db9527a`)**, which is also the restored PR head; the
deferred connector hardening is not included. Prefill 138 + Decode 136,
16 NPUs per node; original image, weights, datasets, launch and
benchmark parameters were retained, with only the second-node address
mapped from 139 to 136. All four cases exited pytest 0 on both nodes
(one passed JUnit case per node). OTT is output token/s; TPOT/TTFT are
ms.

| Case | Performance requests | OTT / required minimum | TPOT / TTFT |
AIME2025 accuracy | Result |
| --- | --- | --- | --- | --- | --- |
| Kimi-K2.6 PD | 60/60 | 355.1593 / 337.024075 | 20.5 / 3268.2 | 90%,
within 93.33±10 | Performance + accuracy passed |
| DeepSeek-V4 Flash PD-prefix | Accuracy only | N/A | N/A | 90%, within
90±10 | Accuracy passed |
| GLM-5.1 W8A8C8 128K | 256/256 | 811.7645 / 282.105876 | 39.8 / 32665.6
| No accuracy item | Performance passed |
| MiniMax-M2.7 PD-prefix | 160/160 | 711.0518 / 698.497 | 34.8 / 17438.2
| 90%, within 93.33±10 | Performance + accuracy passed |

All performance requests above, and the valid controls below, were
checked for actual 1024-token outputs, not just success flags.

**Conditional controls:** historical throughput differences triggered
only the affected performance cases against the same PR base `6d1dd70`,
without this PR, + vLLM 0.30.0 (`ced6857`). Kimi: 355.1593 vs 359.8514
OTT (**-1.30%**); the earlier 7.27% loss was not reproduced in this
comparison. TPOT was 20.5 vs 19.7ms (+0.8ms/+4.06%), and average request
latency +3.48%; a single pair does not establish latency equivalence or
a stable regression. GLM: 811.7645 vs 813.3506 OTT (**-0.20%**), TPOT
39.8 vs 39.4ms. Kimi's original random request pacing affects aggregate
OTT. No alternating reruns or unaffected-model 0.30 controls were added.

Archived evidence:
`main2main-nightly-20261013/pr18229-update-444e962-20261015/`
(`FINAL_REPORT.md`, per-node logs/JUnit, raw AISBench outputs,
token-count audit, controls and diagnostic evidence). Both nodes were
released after testing.

#### Deferred follow-up: multi-group receive-failure reporting (not
included)

The request-level receive-failure hardening change has been removed from
this upgrade PR; the branch is restored to the nightly-tested head
`444e962`. The original four nightlies already passed on this head
**without** that fix, so it is not required for these normal-path
workloads to pass.

The fault-path issue remains real: if a multi-group receive actually
fails, the existing connector can report flat block IDs and trigger the
vLLM 0.31 scheduler guard, terminating Decode EngineCore. This is
handled separately in
[#18823](https://github.com/vllm-project/vllm-ascend/pull/18823),
retaining ordinary non-HMA block-level recovery semantics. The upgrade
PR does not claim fault isolation is fixed.

Development fault-injection results belong to the deferred connector
implementation, not this restored head. No new NPU run was performed
when restoring the exact previously tested code.

#### Historical validation for head `23c8b15`

- New [E2E
workflow](https://github.com/vllm-project/vllm-ascend/actions/runs/38562748688)
and [Docs link
check](https://github.com/vllm-project/vllm-ascend/actions/runs/38562748395)
were triggered after the rebase. Results are pending; previous-head CI
does not validate this rebased head.
- A targeted [comment
command](https://github.com/vllm-project/vllm-ascend/pull/18229#issuecomment-6168149194)
requests `test_deepseek_v4_mtp_full_decode_only` against both supported
upstream targets. The [command
workflow](https://github.com/vllm-project/vllm-ascend/actions/runs/38562831465)
is queued; its actual test results remain pending.
- Ruff check and format check passed for all 72 changed Python files;
Python compilation and diff checks passed. Source-extracted execution of
both real CPP routing regressions passed against the required partition
signatures of the exact main/release refs. This validates dispatch
contracts with lightweight dependency stubs and does not replace full
pytest or NPU execution.
- Existing source-extracted scheduler regressions passed on both version
lanes: eight budget scenarios, two queue paths and empty/fully deferred
queue regressions, including negative controls.
- Local full pytest/Torch/NPU and `bash format.sh ci` remain unavailable
in this Windows environment. They require CI validation.
- Previous head `9330488` passed pre-commit, Docs and both CPU UT lanes
(main 10782 passed / 114 skipped; release 10784 passed / 112 skipped).
Its initial NPU matrix passed 41/42 shards; the remaining main A3 shard
failed in unchanged upstream teardown with `psutil.NoSuchProcess`,
before the MTP golden acceptance assertion. The consequent gate failure
and old-head rerun are historical evidence, not a result for the current
head.

#### Coverage limits and historical evidence

The PR CI selector scans `tests/ut` and `tests/e2e/pull_request`; the
new broadcast/strided token-logprob numerical tests under
`tests/e2e/nightly` are outside that selection. A5, standalone
upstream-worker and coverage-upload jobs were skipped in the inspected
run. Skips are not coverage. No dedicated packed-QK RoPE or V1
profiling-randomization standalone UT is added by this final diff.

Previous head `15f8a3d` passed
[E2E](https://github.com/vllm-project/vllm-ascend/actions/runs/38511018361)
and
[Docs](https://github.com/vllm-project/vllm-ascend/actions/runs/38511018193),
including 42 NPU jobs. Its PR-recorded CPU counts were 10574 passed /
113 skipped for verified main and 10576 passed / 111 skipped for
release, with no failures. Those counts belong to that historical head
and are not asserted as current-head counts.

- vLLM main:
https://github.com/vllm-project/vllm/commit/c4df37dfcc7f72ca41cd43801a468526ecf99a2b

---------

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Co-authored-by: shenzhao <shenzhao9@huawei.com>
weiguihua2 pushed a commit that referenced this pull request Oct 26, 2026
### What this PR does / why we need it?

CPP still carried legacy runner-specific scheduler branches,
configuration checks, documentation, and duplicated performance
scenarios. The default execution path no longer needs that compatibility
surface.

This PR:

- removes the legacy scheduler-output construction and request
bookkeeping branches from `ProfilingChunkScheduler`;
- removes the obsolete runner compatibility validation from CPP
configuration handling;
- keeps the existing startup profiling, online calibration, synchronous
and asynchronous schedulers, and SRF composition unchanged;
- updates CPP tests to cover the default synchronous,
synchronous-with-SRF, and asynchronous scenarios without runner-specific
configuration;
- removes obsolete runner constraints from user and developer
documentation;
- leaves the legacy runner implementation untouched so it can be removed
as one unit separately.

### Does this PR introduce _any_ user-facing change?

No. This is cleanup of legacy compatibility paths. The documented CPP
configuration and default execution behavior remain unchanged.

### How was this patch tested?

Validated the rebased commit `9b5620a90` against the verified vLLM
commit listed below.

- Platform, CPP scheduler, and SRF unit suites: **210 passed, 1
skipped**.
- Worker regression suites covering CPP dummy inputs, PCP partitioning,
model-runner state restoration, and worker profiling (including #18622):
**294 passed, 1 skipped**, using the repository's CPU/mock unit-test
mode.
- Four-card CPP performance E2E: **3 passed**. The existing TTFT
threshold remains **5.45s**:

  | Scenario | Median TTFT |
  | --- | --- |
  | Synchronous | 4.59s |
  | Synchronous + SRF | 4.59s |
  | Asynchronous | 4.62s |

- CPP + SFA + PCP + PP graph E2E added by #18622: **1 passed**. CPP
startup profiling completed successfully before graph inference.
- All repository pre-commit hooks passed in all-files/manual mode. A
checksum-verified, pinned Actionlint 1.7.11 release binary was supplied
through a temporary system-language override after Go environment
bootstrap timed out; the repository configuration was unchanged.
ShellCheck and Actionlint were rerun successfully after installing the
missing ShellCheck tool.
- `ruff check`, `ruff format --check`, Python syntax checks on all
changed Python files, and `git diff --check upstream/main...HEAD`
passed.
- Current-source vLLM Ascend native extensions built and loaded
successfully. vLLM itself used an editable `VLLM_TARGET_DEVICE=empty`
installation.

E2E used four A3 NPU devices with local Qwen3-30B-A3B and
DeepSeek-V3.2-W8A8-Pruning weights, supplied through temporary test-only
model-path overrides. Test source, assertions, topology, and performance
thresholds were unchanged. The two unit-test skips are existing guards
for out-of-tree cudagraph configuration and fixed-token scoring support.


---

### Checklist

#### Testing

- [x] **Boundary / edge-case coverage**: Reviewed the cleanup for
boundary behavior. Existing coverage passed for empty/unready profiling
state, repeated profiling initialization, preemption/waiting edges, and
synchronous/asynchronous scheduler selection. This PR removes legacy
branches without introducing new boundary behavior.
- [ ] **Regression test**: **Not applicable.** This is a cleanup PR, not
a bug fix, and it does not add a new test that fails without a fix.
Existing regression suites were rerun, including the tests previously
added by #18622; those runs do not satisfy the template's requirement to
add a bug-specific regression test in this PR.
- [x] **Error / failure path coverage**: Existing tests for invalid CPP
configuration, profiling initialization failures, missing executors, and
worker dummy-run error propagation passed.
- [x] **Meaningful & reliable tests**: The modified scheduler-selection
tests assert the selected implementation, and retained E2E tests assert
real execution and the existing performance threshold. Validation
completed with 504 unit tests and 4 selected E2E cases passing, plus 2
existing unit-test skips.
- [ ] **Performance impact**: **Partially complete.** Benchmark results
are attached: CPP synchronous, SRF, and asynchronous median TTFTs were
4.59s, 4.59s, and 4.62s, all below the existing 5.45s threshold.
However, this PR retains/updates existing performance guards rather than
adding a new performance regression test, so the template's full
criterion is not marked complete.


- vLLM main:
vllm-project/vllm@c0b6f74

Signed-off-by: dianWang325 <93850926+dianWang325@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

module:tests ready-precise run selected e2e test for pr

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants