Skip to content

[Misc] main2main 1106 - #21005

Open
zhao-stack wants to merge 47 commits into
vllm-project:mainfrom
zhao-stack:codex/main2main-pin-69d27bf8
Open

zhao-stack wants to merge 47 commits into
vllm-project:mainfrom
zhao-stack:codex/main2main-pin-69d27bf8

Conversation

@zhao-stack

@zhao-stack zhao-stack commented Nov 5, 2026 •

Copy link
Copy Markdown
Collaborator

What this PR does / why we need it?

Upgrade baseline

  • Advance the verified vLLM main anchor from 24420b7a341af37a9bc3186e6fc6062512e0aa58 to ba15685ab7f4f5fbed8630bbb7441f8837e76fbe. The complete upstream comparison contains 544 commits.
  • Retain the vLLM 0.33.0 release lane. Version gates below distinguish actual release/main signatures, fields, and module ownership.
  • All 23 upstream vLLM PRs linked below are within this fixed anchor window. The adapters do not advance the pin beyond ba15685a. Metadata, fixture repairs, and comment-only changes without an independent upstream API change are identified explicitly.
  • Follow the same file-by-file format as #11709. The 71 files below follow the current PR diff order; separate rows explain independent changes within a file. Each row links the upstream PR and the exact added downstream line.
  • Reviewed Ascend head: 085accc3, rebased onto official main 1af7c5fc. CI results below refer to this head.

Changes by file

1. .github/vllm-main-verified.commit
Change Upstream change Downstream adaptation Why it is needed
Advance the verified main anchor The complete 544-commit window is 24420b7a...ba15685a; there is no single introducing PR. Set the main pin to ba15685a. CI must install the exact upstream revision for which the adapters below are written.
2. release_notes/fragments/21005.yaml
Change Upstream change Downstream adaptation Why it is needed
Document the compatibility update Release-note metadata for this upgrade and the Gemma4 fixes below; no independent upstream API change. Record the fixed main baseline, retained v0.33.0 support, and Gemma4 initialization repair. Expose the dependency and behavior changes in release notes.
3. tests/ut/core/test_dyntra_lb_scheduler.py
Change Upstream change Downstream adaptation Why it is needed
Keep the PP decode-cadence assertion vLLM #64076: Removes AsyncScheduler.pp_size; the cadence is derived from parallel_config.pipeline_parallel_size. Read the configured PP size and retain the same next-decode-step assertion. Avoid asserting a removed alias while preserving the actual scheduling contract.
4. tests/ut/core/test_profiling_chunk.py
Change Upstream change Downstream adaptation Why it is needed
Follow the native PP cadence configuration vLLM #64076: Removes pp_size while retaining the configured pipeline-parallel decode stagger. Assert PP size 2 and compute the expected next step from parallel_config. Keep the scheduled/skipped-step behavior checked against the real configuration.
5. tests/ut/distributed/kv_transfer/kv_p2p/test_remote_prefill_lifecycle.py
Change Upstream change Downstream adaptation Why it is needed
Use the public KV-block hash vLLM #65831: Replaces the private _block_hash representation with the public block_hash field. Update both un-hashed and hashed block assertions to the public field. Preserve the remote-prefill lifecycle assertions across the new block implementation.
6. tests/ut/distributed/weight_transfer/test_hccl_engine.py
Change Upstream change Downstream adaptation Why it is needed
Model native reload and load-plan defaults vLLM #64336, vLLM #65235: Changes layerwise reload to start_reload / finish_reload(model, config, device) and adds optional load-plan state/payload. Initialize disabled plan fields, provide empty_cache, select reload symbols by version, and assert use_load_plan=False on main. Constructor-bypassing mocks must represent the inherited engine rather than fail on omitted native defaults.
7. tests/ut/distributed/weight_transfer/test_npu_ipc_engine.py
Change Upstream change Downstream adaptation Why it is needed
Match IPC reload finalization vLLM #64336: The main reload lifecycle uses start_reload / finish_reload and forwards the device. Expose both names in the fake reload module and assert the version-correct finalize arguments. Retain the existing packed-importer close assertion with the actual inherited call signature.
8. tests/ut/kv_offload/test_dspark_transfer_cancellation.py
Change Upstream change Downstream adaptation Why it is needed
Initialize asynchronous-KV scheduler state vLLM #65319, vLLM #65285: Adds the async waiting/aborted-load state and cached parked admission reservations. Supply those constructor defaults in the handcrafted cancellation fixture. Keep exercising transfer cancellation instead of failing on unrelated missing fixture fields.
9. tests/ut/kv_offload/utils.py
Change Upstream change Downstream adaptation Why it is needed
Complete fake model registry metadata vLLM #63205: Adds ModelInfo.speculator_config_class for declared/custom speculators. Set speculator_config_class=None on the fake OPT model info. Represent an ordinary non-speculator model under the new registry contract.
10. tests/ut/ops/test_linear.py
Change Upstream change Downstream adaptation Why it is needed
Exercise stacked-shard completeness vLLM #63752: Introduces per-parameter loaded-shard tracking and missing-shard validation. Add real Ascend merged/QKV layer tests for partial loads, complete reloads, and invalid shard IDs; run them on main. Verify the custom constructors retain native completeness checking rather than merely accepting loader calls.
11. tests/ut/ops/test_mla.py
Change Upstream change Downstream adaptation Why it is needed
Test ShardQ keyword compatibility vLLM #63956: Adds the MLA constructor keyword shardq_eligible for the CUDA sparse-MLA optimization. Construct Ascend MLA with both values and check that the hint is not forwarded into the Ascend backend. Accept upstream calls without changing the NPU attention/indexer layout.
12. tests/ut/ops/test_mla_weight_processing.py
Change Upstream change Downstream adaptation Why it is needed
Verify module and implementation hook signatures vLLM #57678: Makes module post-load hooks argument-free while implementation hooks still consume an activation dtype. Supply the stored dtype; call/assert the release or main module signature and retain dense/SFA release-of-weight checks. Keep the distinction between module hooks, backend hooks, and SFA's disposed source weights.
13. tests/ut/patch/platform/test_patch_pp_mtp.py
Change Upstream change Downstream adaptation Why it is needed
Provide the internal prompt-token buffer vLLM #62702: Introduces TokenIdsView consumers of Request._all_token_ids. Add _all_token_ids to the existing structured-output request fixture. Preserve grammar validation behavior using the real request-field contract.
14. tests/ut/patch/platform/test_patch_use_v2_model_runner.py
Change Upstream change Downstream adaptation Why it is needed
Complete the native speculator validator fixture vLLM #63205: Validates the declared speculator_config.speculator_class. Add a disabled-test declaration to the existing PP/speculative configuration. Keep the PP/SP validation assertions while supplying the new native config shape.
15. tests/ut/patch/worker/test_deepseek_pp_embedding.py
Change Upstream change Downstream adaptation Why it is needed
Represent target-embedding capabilities vLLM #63205: The native helper reads uses_target_hidden_states and draft_model_config.may_use_target_embed. Official Ascend #21114 introduced the PP fixture in the inherited base. Populate both DFlash capabilities in that fixture. Exercise the original provisioning/assertion paths instead of failing on absent SimpleNamespace fields.
16. tests/ut/patch/worker/test_patch_bind_kv_cache.py
Change Upstream change Downstream adaptation Why it is needed
Test versioned KV binding and tracker ownership vLLM #55688: Adds distinct layer-cache views and moves ReplaySSM tracker sharing out of binding on main. Cover both binding entry points, the legacy-only tracker hook, tuple storage, and separate scheduler/kernel views. Protect tensor/container identity and prevent re-creating trackers through a removed main hook.
17. tests/ut/patch/worker/test_patch_mm_input_norm.py
Change Upstream change Downstream adaptation Why it is needed
Complete sharded-state loader input vLLM #61380: Reads ModelConfig.revision while resolving checkpoint paths. Set revision=None in the existing fake config. Preserve the legacy shard/missing-weight assertions against the actual loader contract.
18. tests/ut/quantization/test_utils.py
Change Upstream change Downstream adaptation Why it is needed
Declare an actual MultiConnector consumer child vLLM #65060: Computes MultiConnector roles from nested connector roles rather than its top-level kv_role. Add a consumer child to the existing FA-quantization fixture. Continue testing a real consumer configuration; an empty child list no longer represents one.
19. tests/ut/spec_decode/test_dspark_graph_contract.py
Change Upstream change Downstream adaptation Why it is needed
Initialize split-grid graph-dispatch state vLLM #63406: Separates prefill tokens and decode requests, with per-query limits and decode descriptor state. Extend the manually allocated DSpark manager with split fields, decode_max_reqs, and _decode_descs. Keep the existing uniform-draft padding assertions under the new native manager layout.
20. tests/ut/spec_decode/test_eagle_aclgraph_source_regression.py
Change Upstream change Downstream adaptation Why it is needed
Align the existing source assertion with the patch alias vLLM #60989: Moves graph construction into the shared AR module; the versioned patch uses the ar_speculator alias. Update the pre-existing source-string assertion to the actual assignment name. Reflect the patched lookup namespace; this PR does not add the existing AST inheritance test.
21. tests/ut/test_ascend_forward_context.py
Change Upstream change Downstream adaptation Why it is needed
Test MC2 capacity against target graph shapes vLLM #63406: Expands independent draft request grids beyond the target's configured graph bound. Add seven cases for target/draft separation, token caps, TP rounding, and the ALLTOALL fallback. Ensure draft graph maxima cannot silently enlarge target MC2 profiling or communication thresholds.
22. tests/ut/test_platform.py
Change Upstream change Downstream adaptation Why it is needed
Test default caps and split-grid re-entry vLLM #63406: Adds separate prefill/decode lists and limits and checks their consistency on config re-entry. Add explicit-split preservation, off-stride default restoration, and TP-aligned-prefill tests using native config resolvers. Preserve user settings and decode request grids through repeated engine-handshake resolution.
23. tests/ut/worker/test_attn_utils_v2.py
Change Upstream change Downstream adaptation Why it is needed
Mirror the allocator's disabled-feature keyword vLLM #56492: Forwards allocate=None even when extensible allocation is disabled. Accept the keyword in the test allocator and assert it is None. Keep the native allocator integration test meaningful without enabling extensible allocation.
24. tests/ut/worker/test_model_runner_v2.py
Change Upstream change Downstream adaptation Why it is needed
Invoke the factory with the native graph argument vLLM #63406: Changes decode_query_len to a query-width-to-request-limit decode_query_lens mapping on main. Pass the version-correct keyword when exercising the installed ACL graph factory. Continue checking factory/PCP installation against the real caller contract.
25. tests/ut/worker/test_model_runner_v2_kv_cache.py
Change Upstream change Downstream adaptation Why it is needed
Verify ReplaySSM tracker collection and block copies vLLM #55688: Adds replayssm_block_copy_tensors to scheduler-driven cache-block copies. Check collector results including empty lists and profiling, then copy ring-start/committed-count tensors with segmented Mamba storage. Keep tracker metadata synchronized with copied state while preserving connector container/registration behavior.
26. tests/ut/worker/test_model_runner_v2_mamba.py
Change Upstream change Downstream adaptation Why it is needed
Enforce the actual Mamba context constructor vLLM #55688: Requires forward_context to count the state tensors attached to actual layers. Use autospec=True, assert version-specific arguments, layer bindings, block-table identity, and cached context reuse. Catch missing native constructor arguments that an unconstrained MagicMock would accept.
27. tests/ut/worker/test_mtp_pcp_speculator_v2.py
Change Upstream change Downstream adaptation Why it is needed
Cover non-PCP draft query metadata vLLM #63406: Request-grid padding can occur in target FULL graphs even with PCP disabled. Add eager/PIECEWISE/FULL cases and check clamped draft query ends, unchanged target metadata, and shared unaffected buffers. Prevent draft MLA from indexing padding rows outside its real query tensor.
28. tests/ut/worker/test_pcp_profile_budget.py
Change Upstream change Downstream adaptation Why it is needed
Model the native drafting slot budget vLLM #60989: PCP/profile budgeting reads max_num_new_slots_for_drafting; MTP's value is zero. Supply the zero-valued property in the fake MTP/DSpark config. Preserve the original profile-budget assertions rather than fail on an incomplete test double.
29. tests/ut/worker/test_v2_dummy_padding.py
Change Upstream change Downstream adaptation Why it is needed
Complete the dummy graph-manager fixture vLLM #63406: Native dispatch uses split grids, the uniform query width, per-width limits, and decode descriptors. Populate these fields on the object created without the native constructor. Continue validating padded dummy execution with the native manager state.
30. tests/ut/worker/test_worker_v1.py
Change Upstream change Downstream adaptation Why it is needed
Test resolved and explicit memory budgets vLLM #56492: Allows gpu_memory_utilization=None and resolves the default after allocation mode selection. Add cases for an explicit 0.5 budget and the disabled-extensible default. Verify the shared worker helper preserves user values and yields a numeric default.
31. tests/ut/worker/v2/test_aclgraph.py
Change Upstream change Downstream adaptation Why it is needed
Test native graph routing and MoE capture boundaries vLLM #60989, vLLM #63406: Relocates the speculator manager and introduces independent decode request grids. Select the native class and argument shape by version; add eight MoE/communication cases with native candidate creation and dispatch. Check that unsupported FULL captures fall back eagerly with every original request/token preserved.
32. tests/ut/worker/v2/test_entropy_verify.py
Change Upstream change Downstream adaptation Why it is needed
Check both values of the masked-vocabulary hint vLLM #65100: Adds skip_masked_vocab_blocks as a resampling optimization hint. Run both values and assert the existing statistics, rejection, and residual-resampling launch path. Verify signature compatibility without claiming a new NPU masked-block optimization.
33. tests/ut/worker/v2/test_lmhead_tp_utils.py
Change Upstream change Downstream adaptation Why it is needed
Follow the renamed draft-prefill helper vLLM #63406: The request-padding adaptation generalizes the downstream PCP-only metadata helper. Change the injected mock from _get_pcp_draft_prefill_metadata to _get_draft_prefill_metadata. Retain the existing request-bound test; its AST-execution mechanism predates this PR.
34. tests/ut/worker/v2/test_speculator.py
Change Upstream change Downstream adaptation Why it is needed
Mock the real single-step draft entry point vLLM #60989, vLLM #65528: The shared AR refactor is followed by renaming native _generate_draft to _decode. Patch the appropriate parent method in the existing metadata and LM-head-bound tests. Ensure the tests intercept the method actually called by each supported lane.
35. tests/ut/worker/v2/test_standalone_ar_speculator.py
Change Upstream change Downstream adaptation Why it is needed
Add correction-token sequence-bound regressions vLLM #60989: Standalone AR now includes the correction token before dispatching its prefill metadata builder. Add six step/boundary cases, initialize the real max-model-length config source, and assert input immutability. Prevent counting the correction token twice on main while keeping the release increment and cap.
36. vllm_ascend/_310p/worker/v2/model_runner.py
Change Upstream change Downstream adaptation Why it is needed
Forward 310P's native graph shape mapping vLLM #63406: Main's model graph manager consumes query-width-to-request-limit mappings rather than a scalar width. Pass the scalar on release and get_decode_cudagraph_query_lens(...) on main. Keep the copied 310P initializer compatible with the same graph contract as the common runner.
37. vllm_ascend/_310p/worker/v2/spec_decode/mtp_speculator.py
Change Upstream change Downstream adaptation Why it is needed
Reconnect 310P to the native single-step AR loop vLLM #60989, vLLM #65528: The shared AR loop uses the renamed _decode entry point on main. Call the release _generate_draft or main _decode directly and expose the Ascend wrapper as _decode. Retain 310P's capture-time pageable-H2D avoidance and out-of-capture metadata update.
38. vllm_ascend/_310p/worker_310p.py
Change Upstream change Downstream adaptation Why it is needed
Resolve the 310P memory-utilization default vLLM #56492: The utilization field may remain None until allocation-mode-dependent resolution. Use the common resolved-utilization helper for the startup budget and diagnostic. Avoid multiplying total memory by None while retaining RC shared-memory handling.
39. vllm_ascend/ascend_forward_context.py
Change Upstream change Downstream adaptation Why it is needed
Derive MC2 capacity from target shapes vLLM #63406: The legacy token union now includes independent one-token draft graphs, potentially larger than target graphs. Combine target prefill capacity with native target decode shapes and token caps before existing TP/per-rank limits. Prevent draft-only maxima from inflating MC2 profiling and communication thresholds.
40. vllm_ascend/core/dyntra_lb_scheduler.py
Change Upstream change Downstream adaptation Why it is needed
Version-gate the retired cascade prefix contract vLLM #64076: Deletes get_num_common_prefix_blocks and SchedulerOutput.num_common_prefix_blocks. Compute and pass the old field only on v0.33.0. Avoid missing-method/invalid-keyword failures on main without changing prefix-cache ownership.
41. vllm_ascend/core/recompute_scheduler.py
Change Upstream change Downstream adaptation Why it is needed
Adapt recompute scheduler output vLLM #64076: Deletes the legacy cascade prefix calculation and output field. Build release-only common_prefix_kwargs; omit it on main. Retain recompute scheduling while matching the native SchedulerOutput constructor.
42. vllm_ascend/core/scheduler_profiling_chunk.py
Change Upstream change Downstream adaptation Why it is needed
Adapt profiling/chunk scheduler output vLLM #64076: Removes the common-prefix API and dataclass member. Restrict the legacy calculation/constructor argument to v0.33.0. Prevent copied profiling/chunk scheduling code from calling a removed native API.
43. vllm_ascend/distributed/kv_transfer/kv_pool/kv_offload/native/cpu_npu.py
Change Upstream change Downstream adaptation Why it is needed
Translate resolved device pointers to NPU DMA descriptors vLLM #56076: Offload workers receive DevicePointers with resolved addresses, copy sizes, group counts, and logical block offsets. Preserve release block-ID descriptors; add a main pointer path that computes only CPU-side addresses and handles empty groups/partial chunks. Keep device address ordering and actual byte counts correct when physical CPU chunk stride differs from copy size.
Preserve the asynchronous transfer lifecycle vLLM #56076: Changes submit-load/store payloads to resolved device pointers. Accept both versioned payloads and share the existing stream/event/descriptor-buffer lifetime handling. Keep descriptor buffers alive until completion and preserve DMA ordering for load/store.
44. vllm_ascend/models/deepseek_v4/vl_model.py
Change Upstream change Downstream adaptation Why it is needed
Avoid a second language-model post-load pass vLLM #57678: The loader walks children first and invokes each module hook itself. Return from the VL wrapper on main; retain the release delegation. Avoid running non-idempotent weight packing/fusion or source-weight disposal twice.
45. vllm_ascend/models/deepseek_v41/vl_model.py
Change Upstream change Downstream adaptation Why it is needed
Keep V4.1 VL finalization version-correct vLLM #57678: Child hooks are already invoked by the main loader's children-first walk. Suppress only the main parent-to-language-model forwarding. Keep release finalization while avoiding repeated processing on main.
46. vllm_ascend/models/gemma4_mm.py
Change Upstream change Downstream adaptation Why it is needed
Initialize inherited multimodal parallelism state vLLM #60314: Native Gemma4 image/video consumers read use_data_parallel initialized from mm_encoder_tp_mode. Initialize the same config-derived field in the copied Ascend constructor. Inherited encoder routing needs the field; forcing False would ignore the configured parallelism.
Initialize the native vision normalization module vLLM #65577: Native Gemma4 embedding/capture reads vision_input_norm produced by build_mm_input_norm. Build it on main inside the existing vision-tower context; leave release construction unchanged. Prevent a missing-field failure while retaining native normalization and Ascend quantized projection handling.
47. vllm_ascend/models/glm5next/kda.py
Change Upstream change Downstream adaptation Why it is needed
Restore stacked state after PCP allocation vLLM #63752: The new stacked-linear constructor declares legal shards and initializes per-parameter load tracking. Initialize shard_ids and loaded_shard_ids after the PCP-specific allocator. The custom constructor bypasses the native initializer but inherits its weight loader and validator.
48. vllm_ascend/models/layer/attention/layer.py
Change Upstream change Downstream adaptation Why it is needed
Accept argument-free DSA module hooks vLLM #57678: Module hooks become argument-free; backend implementation hooks still receive dtype. Store the default activation dtype and make the module argument optional before forwarding to the implementation. Support the main loader without breaking release callers or backend weight processing.
49. vllm_ascend/models/minimax_m3/msa_m3.py
Change Upstream change Downstream adaptation Why it is needed
Track all five MiniMax M3 fused shards vLLM #63752: Stacked-linear validation accepts the parameter and records which logical shards were loaded. Declare q/k/v/index_q/index_k, initialize load tracking, forward param from both loaders, and retain the release validation branch. Preserve missing-shard detection for the custom five-way fused projection.
50. vllm_ascend/ops/linear.py
Change Upstream change Downstream adaptation Why it is needed
Initialize tracking in custom merged/QKV constructors vLLM #63752: Native merged and QKV loaders inherit stacked-shard validation and per-parameter tracking. Initialize the skipped native state and declare merged logical shard IDs. Custom Ascend allocation must still satisfy the inherited loader's completeness contract.
51. vllm_ascend/ops/mla.py
Change Upstream change Downstream adaptation Why it is needed
Accept the upstream ShardQ constructor hint vLLM #63956: Native sparse-MLA callers pass shardq_eligible, including when False. Accept and discard the CUDA hint alongside the existing indexer hint. Keep constructor compatibility while retaining Ascend's own attention/indexer layout.
Preserve dense/SFA post-load dispatch vLLM #57678: Native MLA module hooks drop the dtype argument, while Ascend backend hooks retain it. Resolve omitted dtype from the attention module; call dense native hooks by version and keep direct SFA/DCP backend handling. Avoid both signature errors and reprocessing SFA weights already released by the backend.
52. vllm_ascend/ops/triton/mamba/postprocess.py
Change Upstream change Downstream adaptation Why it is needed
Respect ReplaySSM temporal-copy ownership vLLM #55688: The native fused launcher passes SKIP_TEMPORAL_STATE_COPY when temporal migration belongs to the ring materializer. Accept the constexpr; skip only temporal state copies when requested, after accepted-count normalization. Keep convolution copies and count updates intact while avoiding redundant temporal migration.
53. vllm_ascend/ops/triton/mamba/precopy.py
Change Upstream change Downstream adaptation Why it is needed
Accept temporal-only zero-bias precopy vLLM #55688: Native precopy dispatch supplies ZERO_TEMPORAL_TOKEN_BIAS for ReplaySSM. Add a default-False constexpr and zero the bias only for non-convolution state. Preserve legacy/conv offsets, request mapping, tiling, and the existing NPU pointer-cast behavior.
54. vllm_ascend/patch/__init__.py
Change Upstream change Downstream adaptation Why it is needed
Document the actual patch lookup and tracker contract vLLM #60989, vLLM #55688: Shared AR owns main decode graph construction, and ReplaySSM adds scheduler-copy tracker collection. Update patch documentation for both namespaces and the retained tracker collector. Documentation-only alignment with the production adapters; it introduces no extra patch behavior.
55. vllm_ascend/patch/platform/patch_balance_schedule.py
Change Upstream change Downstream adaptation Why it is needed
Keep the balance scheduler on the native output contract vLLM #64076: Removes the deprecated cascade prefix API/field. Compute and pass that field only in the release branch. Prevent the copied balance schedule from referencing deleted main contracts.
56. vllm_ascend/patch/platform/patch_speculative_config.py
Change Upstream change Downstream adaptation Why it is needed
Preserve legacy DSpark identity across native normalization vLLM #63205: Native hf_config_override renames the legacy DSpark architecture before returning. Remember the original Qwen3/DSpark identity before the upstream override, then copy the legacy nested mask/target-layer fields. Architecture renaming must not cause the Ascend legacy-checkpoint normalization to be skipped.
57. vllm_ascend/patch/worker/__init__.py
Change Upstream change Downstream adaptation Why it is needed
Override 310P's shared AR manager lookup vLLM #60989: Main constructs decode graphs from the shared autoregressive module. Reapply AutoRegressiveAclGraphManager310 to that namespace after the common patch. 310P must retain its specialized graph manager at the actual main construction site.
58. vllm_ascend/patch/worker/patch_bind_kv_cache.py
Change Upstream change Downstream adaptation Why it is needed
Separate layer views and tracker ownership vLLM #55688: Adds layer_kv_caches and removes tracker-sharing responsibility from native binding. Keep original runner storage, bind the optional layer view into forward context, and invoke legacy tracker sharing only on release. Retain scheduler storage identity while honoring main's new tracker lifecycle.
59. vllm_ascend/patch/worker/patch_eagle_speculator.py
Change Upstream change Downstream adaptation Why it is needed
Patch the module that constructs AR graphs vLLM #60989: Moves the main manager implementation/creation to autoregressive; release retains target-dependent AR. Select the versioned module and patch both main shared/target lookup sites. Replacing only the old module would let the actual native caller construct a CUDA manager.
60. vllm_ascend/patch/worker/patch_model_runner.py
Change Upstream change Downstream adaptation Why it is needed
Follow config-driven graph selection and constructor keywords vLLM #65091, vLLM #63406: Breakable graph selection reads CompilationConfig; main graph construction accepts decode_query_lens. Select the release or main graph predicate and keyword before constructing the manager. Keep graph configuration and the copied initialization path consistent with upstream.
Collect tracker tensors for inherited block copies vLLM #55688: Native scheduler-driven block copy consumes the collector's ReplaySSM ring metadata tensors. Collect them after cache/state initialization on main, retaining release binding-time sharing. Avoid a missing runner field and keep ring metadata in lockstep with copied Mamba state.
61. vllm_ascend/platform.py
Change Upstream change Downstream adaptation Why it is needed
Regenerate derived split grids after default-cap restoration vLLM #63406: Native config stores derived prefill/decode grids and validates them again on re-entry. Clear derived split fields when restoring an Ascend default cap, then let native resolution regenerate them. Avoid mixing stale derived split sizes with the restored legacy token grid.
Align only the prefill token grid for TP vLLM #63406: Prefill sizes count tokens; decode sizes count requests and feed a derived shared token union. Filter split prefill tokens for TP alignment, preserve decode requests, and rebuild the union through native helpers. A decode request count need not be divisible by TP; handshake re-entry must remain valid.
Preserve explicit split-grid configuration vLLM #63406: Users can set separate lists, caps, or decode token budgets. Disable the Ascend reduced-default-cap adjustment when any split field is explicitly set, including empty/zero values. User-owned split configuration must take precedence over derived Ascend defaults.
62. vllm_ascend/worker/v2/aclgraph_utils.py
Change Upstream change Downstream adaptation Why it is needed
Express the versioned graph input type vLLM #63406: Main passes a Mapping[int, int] where release passes one query width. Widen the ACL graph wrapper parameter annotation to the accepted scalar/mapping contract. Keep type checking consistent with the forwarded runtime shape; this row is a type adaptation.
63. vllm_ascend/worker/v2/attn_utils.py
Change Upstream change Downstream adaptation Why it is needed
Accept the disabled extensible-allocator keyword vLLM #56492: Native cache initialization forwards a keyword-only allocator even when it is None. Accept allocate=None and explicitly reject non-None custom allocation. Keep Ascend's existing allocation/reshape layout; this does not implement extensible/VMM caches.
64. vllm_ascend/worker/v2/model_runner.py
Change Upstream change Downstream adaptation Why it is needed
Represent disabled extensible cache state vLLM #56492: Inherited main dummy/profile paths inspect extensible_kv_cache on all runners. Initialize it to None in the Ascend runner. Preserve the non-VMM path while satisfying the native object-state contract.
Forward native graph selection and shape arguments vLLM #65091, vLLM #63406: Main's breakable-graph predicate takes config and its manager factory uses query-width mappings. Pass CompilationConfig and accept versioned factory keywords, forwarding the complete mapping. Avoid selection/signature mismatches in the copied model-runner path.
65. vllm_ascend/worker/v2/model_states/mamba_hybrid.py
Change Upstream change Downstream adaptation Why it is needed
Provide bindings to lazy Mamba context creation vLLM #55688: The new native constructor counts state tensors from actual static layer bindings. Supply static_forward_context on main while retaining release creation and lazy cached initialization. Fix the missing constructor argument without flattening layer storage or changing block tables.
66. vllm_ascend/worker/v2/spec_decode/dflash/aclgraph.py
Change Upstream change Downstream adaptation Why it is needed
Keep DFlash graph construction compatible vLLM #63406: Main introduces the keyword decode_query_lens rather than the release scalar parameter. Accept both contracts and forward the version-correct scalar/mapping to the native parent. Preserve the DFlash manager's speculator binding and graph-update behavior.
67. vllm_ascend/worker/v2/spec_decode/rejection_sampler_utils.py
Change Upstream change Downstream adaptation Why it is needed
Accept a resampling optimization hint vLLM #65100: Adds the optional skip_masked_vocab_blocks argument to native rejection-sampler calls. Accept the keyword with default False and retain the full NPU residual scan. Avoid a new-keyword TypeError without claiming the CUDA optimization is implemented on NPU.
68. vllm_ascend/worker/v2/spec_decode/standalone_ar/speculator.py
Change Upstream change Downstream adaptation Why it is needed
Count the standalone correction token once vLLM #60989: Main adds the target correction token before the standalone prefill metadata builder. Apply the downstream +1 and max-length clamp only for release step 0. Avoid overstating main draft sequence bounds by one while preserving input immutability and later steps.
69. vllm_ascend/worker/v2/spec_decode/target_dependent_ar/aclgraph.py
Change Upstream change Downstream adaptation Why it is needed
Import the manager from its versioned owner vLLM #60989: Moves SpeculatorCudaGraphManager to shared autoregressive graph utilities. Import from target-dependent AR on release and shared AR on main. Keep the Ascend subclass attached to the real native implementation.
Preserve graph mapping and request-grid limits vLLM #63406: Main separates query-width limits from independent request capture sizes. Accept/forward the complete mapping and request grid; use only the maximum width to distinguish draft prefill from one-token decode. Do not collapse a multi-width contract to a scalar or discard native request limits.
Exclude unsupported MoE FULL capture shapes vLLM #63406: Independent one-token draft grids can extend into batches selecting ALLTOALL communication. Filter only those main MoE FULL capture candidates using the existing communication policy. ALLTOALL preprocessing can synchronize dynamic token counts on the host; native eager dispatch still processes the full batch.
70. vllm_ascend/worker/v2/spec_decode/target_dependent_ar/speculator.py
Change Upstream change Downstream adaptation Why it is needed
Reconnect the native AR decode entry vLLM #60989, vLLM #65528: Shared AR extraction is followed by renaming the single-step method to _decode. Call the native method by version and bind _decode to the Ascend wrapper. Preserve LM-head padding and the post-step FIA metadata update when main's loop changes lookup sites.
Normalize non-FULL draft MLA query ends vLLM #63406: Target FULL graph request padding can now occur without PCP. Generalize the metadata helper and apply it to main eager/PIECEWISE draft prefill; preserve FULL and target metadata. Keep cumulative query ends within the real draft query rows without mutating target graph buffers.
71. vllm_ascend/worker/worker.py
Change Upstream change Downstream adaptation Why it is needed
Resolve allocation-mode-dependent memory defaults vLLM #56492: Makes gpu_memory_utilization optional and exposes resolved_gpu_memory_utilization. Use a shared helper for budget calculation and diagnostics, preserving explicit values. Avoid total_memory * None and retain the native default rather than hard-coding a ratio.
Clarify unchanged KV-builder routing Both supported versions already use the inherited platform KV-cache builder; no new upstream contract is introduced by this comment. Add a comment documenting the shared builder routing. Comment-only rebase alignment; the executable grouping logic is unchanged.

Compatibility and review notes

  • Preserve the release/main split at real native contracts: scheduler output, post-load hooks, KV binding/ReplaySSM ownership, graph-manager arguments, AR entry points, and resolved memory defaults. Constructor-bypassing test doubles are updated to model those contracts; existing behavioral assertions remain.
  • Graph adapters preserve prefill-token versus decode-request units, native query-width mappings, user-specified split limits, and target-versus-draft capacity. Filtering unsupported MoE FULL capture candidates retains eager processing of the original batch.
  • Accepting the ShardQ and masked-vocabulary hints does not enable their CUDA-specific optimizations on NPU. Accepting allocate=None and initializing extensible_kv_cache=None preserves the existing allocator; this PR does not implement extensible/VMM cache allocation.
  • The five independent CI rebase-guard workflow changes have been reverted and have no remaining PR diff. They are outside this main2main upgrade.
  • The newly introduced tests/ut/test_main2main_v033_contracts.py AST suite was removed. Existing source/AST-based tests inherited from the base are retained. The fixture and assertion-name updates above do not introduce another AST-only suite.

Does this PR introduce any user-facing change?

The verified main compatibility baseline advances to the fixed SHA above while retaining vLLM v0.33.0 support. The changes restore compatibility with native scheduling, loading, graph execution, speculative decoding, Mamba, offloading, and Gemma4 initialization contracts. The release note is release_notes/fragments/21005.yaml; passing hardware behavior is not established by the current CI results.

How was this patch tested?

Current-head E2E run 42987360392 has completed for Ascend 085accc3:

  • Pre-commit: passed. Job 130412027084 passed pre-commit and parallel mypy checks for Python 3.10, 3.11, and 3.12.
  • v0.33.0 CPU lane: passed. Job 130416805172: 16950 passed, 102 skipped, 34 warnings.
  • Fixed-main CPU lane: failed. Job 130416805294, installing upstream ba15685a: 29 failed, 16937 passed, 86 skipped, 27 warnings. The unresolved failures are 2 Kimi gate-loading cases missing AscendMergedColumnParallelLinear.shard_ids, 7 KDA PCP projection cases missing KDAInputParallelLinear.shard_ids, and 20 Mamba platform-alignment cases whose fixture lacks use_flashinfer_replayssm. These failures are not reported as infrastructure-only failures or as fixed.
  • Hardware validation: not executed. The CPU gate failed; downstream selected-test, upstream-test, and A5 hardware jobs were skipped. Cache preparation and test selection passing do not establish NPU/E2E correctness.
  • Local syntax, Ruff lint/format, and whitespace checks passed for the remaining changed Python files. Source-boundary probes used mocked allocation and do not replace CPU or hardware execution. Older-head results and skipped cases are not counted as validation of this head.

@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 advances the verified vLLM main branch pin to a newer commit (69d27bf8) and updates the release version to v0.33.0. It includes comprehensive adaptations to ensure compatibility with upstream changes in graph mode, speculative decoding, and weight management. The changes are designed to keep the Ascend-specific implementation in sync with the evolving vLLM main branch while maintaining support for the v0.33.0 release.

Highlights

  • vLLM Main Pin Advancement: Advanced the verified vLLM main compatibility baseline to commit 69d27bf8, ensuring alignment with recent upstream developments.
  • Release Alignment: Updated the vLLM release compatibility and Dockerfile defaults to v0.33.0, maintaining consistency across the repository.
  • Compatibility Adaptations: Implemented various compatibility adaptations for graph mode, speculative decoding, weight-loading, and KV offload to support the new main baseline.
  • Test Suite Updates: Updated multiple test files to accommodate API changes in the new vLLM baseline, including adjustments to KV cache planning and speculative decoding logic.
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. ↩

zhao-stack added a commit to zhao-stack/vllm-ascend that referenced this pull request Nov 5, 2026
Revert the 15 main-pin commits from c1ab53d through fd288f1, including the main-only split-grid follow-up 1081583. Their individual records and original SHA provenance are retained in PR vllm-project#21005. Restore the exact release-only f9880ef tree, including verified main pin 24420b7a and v0.33.0. No release upgrade commit is reverted.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>

@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 updates the verified vLLM main commit pin to 69d27bf8002a4634de1699c95fb0aeb22fb86ca5 and bumps the release tag to v0.33.0 across Dockerfiles, documentation, and tests. It adapts the codebase to upstream changes in vLLM v0.33.0 by removing legacy v0.32.0 compatibility shims, updating KV-cache planning imports, and adjusting speculative decoding, weight-loading, and KV offload compatibility. The review feedback correctly identifies that the PR title and summary violate the repository style guide and provides a structured suggestion to align them with the required format.

Comment thread .github/vllm-main-verified.commit Resolved
@github-actions

github-actions Bot commented Nov 5, 2026

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.

@zhao-stack zhao-stack changed the title [Misc][main2main] Advance verified vLLM main pin to 69d27bf8 [Misc][main2main] Advance verified vLLM main pin to ba15685a Nov 6, 2026

zhao-stack commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator Author

/rerun
[Bot]: rerun completed.

Rerun (failed jobs only):

  • E2E

1 similar comment

zhao-stack commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator Author

/rerun
[Bot]: rerun completed.

Rerun (failed jobs only):

  • E2E

@zhao-stack
zhao-stack force-pushed the codex/main2main-pin-69d27bf8 branch 2 times, most recently from 711cd85 to 39624fe Compare November 9, 2026 01:36

zhao-stack commented Nov 9, 2026 •

Copy link
Copy Markdown
Collaborator Author

/rerun
[Bot]: rerun completed.

Rerun (failed jobs only):

  • E2E

Failed:

  • Recipes Preview Comment: still in progress, retry /rerun after completion

Copy link
Copy Markdown
Collaborator Author

/rerun

weiguihua2 pushed a commit that referenced this pull request Nov 9, 2026
### What this PR does / why we need it?

Upgrade vLLM release compatibility and Dockerfile defaults to
**v0.33.0** (`4ba787ec9959e566d3b587a796dff07673324da5`). The verified
vLLM main pin remains **`24420b7a341af37a9bc3186e6fc6062512e0aa58`**.
The separate main-pin upgrade is in #21005.

The five signed-off release commits are rebased onto Ascend main
`7ead678c715ccf292d19f6b2f2ff41c0fe0e4052`:
- `19e32a64e`: release version guards, Dockerfile defaults, metadata and
documentation.
- `3708328d6`: v0.33 CPU expectations and KV planner calls.
- `d0e83d582`: Kimi fused output-gate compatibility.
- `0362753e7`: v0.33 DSpark sampling fixture.
- `70c2b2be9`: PCP tuple contract and DP sync fixtures.

The clean release history avoids replaying reverted main-pin changes.
After the previous rebase, upstream #20361 changed adaptive verification
and CI's live-main rebase conflicted in three files before tests. This
rebase keeps upstream's capability-driven allocator, its legacy/Triton
tests, and its 3/4-field allocation handling with admitted-draft
propagation. The obsolete overlapping release hunks were removed; the
other four release patches remain identical. No unrelated upstream
feature fix, main-pin upgrade or benchmark threshold change is included.

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

The supported release baseline and Dockerfile defaults become vLLM
v0.33.0. The verified main pin is unchanged. Release note:
`release_notes/fragments/20627.yaml`.

### How was this patch tested?

- Current head: `70c2b2be95cd66808c88e46aae0bf1c98f951de0`.
[E2E42000109512](https://github.com/vllm-project/vllm-ascend/actions/runs/42000109512)
has passed pre-commit, test selection and both CPU lanes; each CPU lane
reports **16516 passed / 109 skipped**, including all three allocator
compatibility tests and successful rebase. Attempt 2 is now terminal
**success**: **44/44 hardware shards passed**, ci-gate passed, and **50
jobs succeeded / 8 skipped / 0 failed** overall. Skipped jobs are not
test passes.
- Python AST parsing, Ruff lint and Ruff format checks pass for all 104
changed Python files. `git diff --check` passes and CI-style rebase onto
the current base succeeds as a no-op.
- Range-diff confirms the four subsequent release patches are identical.
The first patch differs only by removal of the adaptive-verification
hunks superseded by upstream. The allocator patch and its tests exactly
match current upstream.
- Existing adaptive-verification tests cover legacy allocator wrapping
and preservation of the Triton allocator. All three allocator tests
passed in both current-head CPU lanes; local Windows lacks the Torch
runtime.
- Full `bash format.sh ci` was attempted with bounded local
initialization and stopped at actionlint setup; the task's own formatter
process trees were cleaned. A complete local lint pass is not claimed.
- Previous head `5f9371a39`,
[E2E41996832071](https://github.com/vllm-project/vllm-ascend/actions/runs/41996832071):
pre-commit passed; both CPU lanes and test selection failed during
rebase, before tests, with the three adaptive-verification conflicts
repaired here. Those failures are not runtime test failures.
- Historical head `6e4535561`: CPU lanes each passed 16398 tests / 109
skips, and 43/44 hardware shards passed. Release A2 part7 failed before
tests on the PyTorch ninja index HTTP503; those old-head results do not
validate this head.
- Attempt 1 [main24420 A3
job127162106257](https://github.com/vllm-project/vllm-ascend/actions/runs/42000109512/job/127162106257)
failed the Qwen DSpark GDN fixed-versus-plain comparison
(prompt2/token19, logprob difference 0.1472 > 0.1378). On unchanged
published head, the targeted [attempt 2
job127250533233](https://github.com/vllm-project/vllm-ascend/actions/runs/42000109512/job/127250533233)
passed the same file (2 tests), the full shard (10 passed / 1 skipped),
and
[ci-gate127271942785](https://github.com/vllm-project/vllm-ascend/actions/runs/42000109512/job/127271942785)
passed. No tolerance or source changes were made between attempts. The
rerun was triggered by `vllm-ascend-ci`; this monitor only observed it.
Runtime vLLM remains `0.1.dev1+g24420b7a3.empty`; Ascend is
`0.19.1rc2.dev3366+g3603d176e` versus attempt 1 `...+g07b5dafcd`,
because CI rebases onto live main and produces a local detached commit.
Exact rebased full SHA/tree, image digest and weight revision are not
established. The first numerical failure's root cause remains unproven;
rerun success does not by itself prove fluctuation or exclude every
migration association. The release counterpart also passed the same two
tests.
- Follow-up fixes are limited to v0.33 migration regressions and
rebase/restore operations. Other-code failures will be reported
separately. Skipped or unexecuted coverage is not counted as passing.
- Historical A2 performance, four-node Kimi DSpark, A5 GLM dtype and A5
DSV4 layout risks remain outside ordinary-CI closure. This repair did
not post a new nightly comment or restart local hardware validation.

- vLLM main:
vllm-project/vllm@24420b7

---------

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
@zhao-stack
zhao-stack force-pushed the codex/main2main-pin-69d27bf8 branch from 5cdf3f6 to 0a5201f Compare November 9, 2026 06:40
@github-actions github-actions Bot removed the documentation Improvements or additions to documentation label Nov 9, 2026
vLLM #55688 requires forward_context to size per-layer Mamba state buffers. Preserve the release constructor and lazy metadata initialization, and enforce the installed native signature in the context regression.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
vLLM #55688 passes ZERO_TEMPORAL_TOKEN_BIAS to the globally replaced kernel. Match its optional flag and temporal-only bias semantics while preserving convolution bias, legacy callers and the Ascend pointer-copy workaround.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Keep all source-executed kernel cases and assertions while making the exec-installed callable visible to mypy on Python 3.10, 3.11 and 3.12.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Mirror the native collector added by vLLM #55688 in the existing Ascend KV initializer. The inherited update_requests path reads this list on hybrid prefix-cache block copies. Preserve release/old-main initialization, lazy model-state binding, cache containers and connector registration. Extend profiling and tracker-copy regressions without relaxing assertions.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Match the config-derived encoder DP flag introduced by vLLM #60314 and the optional input normalization initialization from #65577. Retain release and prior-main APIs, ModelSlim tower quantization, and original assertions.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Gate deprecated scheduler prefix fields and Gemma4/Mamba/ReplaySSM API differences with vllm_version_is. Separate split-grid API availability from optional configuration values, preserving None, empty-list, cap restoration and TP/MC2 behavior. Align fixtures and add explicit/default cap regression coverage without dropping existing assertions.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Model the explicit vLLM version alongside the ReplaySSM hook in cache-binding fixtures. Follow the renamed draft metadata helper and select the native release/main single-step draft method when mocking capture. Preserve existing test cases and assertions.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
The pinned vLLM speculator configuration refactor (#63205) makes spec_decode_needs_target_embed read uses_target_hidden_states and draft_model_config.may_use_target_embed. Supply those DFlash capabilities in the official PP embedding fixture, preserving all test cases and assertions and release compatibility.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Official main now imports vllm_version_is at module scope for release-only adaptive verification. Remove the duplicate import replayed from the upgrade while preserving both version-gated behaviors.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Remove test_main2main_v033_contracts.py as requested. Keep existing upstream AST tests and their compatibility fixture changes unchanged pending scope review.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Initialize KDA merged shard IDs and per-parameter load tracking required by vLLM #63752. Complete constructor-bypassing gate fixtures and the Mamba alignment config fixture for the pinned-main APIs, preserving all existing assertions.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Remove the deprecated v0.33 common-prefix block calculation, its SchedulerOutput forwarding, and unused imports. The release SchedulerOutput supplies its default, while verified main no longer exposes this deprecated contract.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Remove deprecated common-prefix block calculations and SchedulerOutput keyword forwarding from the dyntra, recompute, and profiling chunk schedulers. Clean up imports made unused by these deletions, matching the balance scheduler cleanup.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
The cascade compatibility cleanup removed Any even though existing helper and policy annotations still reference it, causing ten Ruff F821 errors. Restore the typing import and verify all four scheduler files with CI's Ruff 0.14.0 check and format checks.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Remove the v0.33 exclusion from non-FULL draft prefill metadata normalization. Request padding in target FULL graphs also exists on v0.33, so eager and PIECEWISE MLA drafts must clamp query lengths to real decode rows on both supported versions. Add regression coverage for both version branches and all three graph modes while preserving target metadata.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Use the upstream query-shape resolver on main while preserving integer query lengths on v0.33.0. Cover the caller contract for both versions across full, eager, and mixed graph modes.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
vLLM main resolves ModelConfig from vllm.config after the speculator config refactor. Patch that lookup on main and retain the speculative-module lookup on v0.33.0 so the real configuration validators receive the intended draft fixture.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
@zhao-stack
zhao-stack force-pushed the codex/main2main-pin-69d27bf8 branch from 3cd2f57 to 16b3cce Compare November 13, 2026 09:01
zhao-stack added a commit to zhao-stack/vllm-ascend that referenced this pull request Nov 13, 2026
…16b3cce)

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Model self-contained Kimi/Qwen/GLM DSpark drafts with their declared speculator config class so upstream adaptation preserves the draft architecture and real validation remains exercised.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
zhao-stack added a commit to zhao-stack/vllm-ascend that referenced this pull request Nov 13, 2026
…3145cd9)

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Comment on lines 287 to +288
if self.pcp_manager is not None:
attn_metadata = self._get_pcp_draft_prefill_metadata(attn_metadata)
attn_metadata = self._get_draft_prefill_metadata(attn_metadata)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I reproduced this on v0.33 with the Kimi K3 MTP test by changing the capture sizes to [8]: one real request has 2 query tokens, while the target FULL graph pads to 8. The eager draft reuses the target’s cumulative query lengths [2,4,6,8], but MLA slices the query to 2 rows, causing the FIA length mismatch. This issue is therefore not specific to the main update; #63406 exposed it under the existing test configuration. Could we reuse the existing PCP adjustment directly in propose() by replacing the PCP-only condition with if attn_metadata is not None, rather than adding another call in _prefill()? The helper modifies a copy, and FULL replay uses the original metadata from model_state for graph parameter updates, so it does not consume the adjusted copy. I tested this placement on v0.33 with both draft eager and draft FULL, and both passed with FULL replay confirmed.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Thanks for the repro! I updated propose() to reuse the existing metadata adjustment whenever attn_metadata is available and removed the extra call from _prefill().

Apply the existing query-length adjustment whenever target attention metadata is available. Exercise eager, piecewise, and full draft dispatch through propose.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>
Expect direct prefill calls to preserve their inputs and supply dictionary attention metadata when testing propose DP synchronization.

Signed-off-by: zhao-stack <80399320+zhao-stack@users.noreply.github.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants