-
Notifications
You must be signed in to change notification settings - Fork 2.7k
[TRTLLM-15304][fix] MoE and MTP fixes for large hybrid-attention FP8 serving #17635
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Wanli-Jiang
merged 6 commits into
NVIDIA:main
from
Wanli-Jiang:user/williamj/qwen35-large-moe-serving-fixes
Aug 18, 2026
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
274c675
[TRTLLM-15304][perf] keep MoE chunk bookkeeping in Python state
Wanli-Jiang 8939e74
[TRTLLM-15304][fix] align MTP ADP token metadata
Wanli-Jiang ce4936b
[TRTLLM-15304][fix] size FP8 MoE activation backing independently
Wanli-Jiang 190b004
[TRTLLM-15304][fix] keep zero FP8 MoE activation blocks finite
Wanli-Jiang 67e4925
[TRTLLM-15304][perf] select cooperative routing for large expert tiers
Wanli-Jiang c3adc7d
[TRTLLM-15304][fix] log forced MoE communication strategy
Wanli-Jiang File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
cpp/tensorrt_llm/kernels/trtllmGenKernels/blockScaleMoe/routing/RoutingCustomSelection.h
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| /* | ||
| * Copyright (c) 2026, NVIDIA CORPORATION. All rights reserved. | ||
| * | ||
| * Licensed under the Apache License, Version 2.0 (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * | ||
| * http://www.apache.org/licenses/LICENSE-2.0 | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, | ||
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
|
|
||
| #pragma once | ||
|
|
||
| #include "RoutingKernel.h" | ||
|
|
||
| #include <cstdint> | ||
|
|
||
| namespace moe::dev::routing::routingCustom | ||
| { | ||
|
|
||
| //! Whether the cooperative block kernel is the preferred launcher for this shape. | ||
| //! | ||
| //! Split out of run() so the selection table can be unit tested without launching a | ||
| //! kernel. This is host-only and holds no state: both escape hatches, | ||
| //! TLLM_ROUTING_DISABLE_COOP_BLOCK and TLLM_ROUTING_COOP_BLOCK_MIN_EXPERTS, are read by | ||
| //! the caller and applied here only through arguments. | ||
| //! | ||
| //! \param preprocessType routing preprocess applied before top-k. | ||
| //! \param postprocessType routing postprocess applied to the top-k scores. Paired with | ||
| //! preprocessType it identifies the policy, exactly as dispatchRoutingPolicy() does. | ||
| //! \param numTokens number of routing tokens in this launch. | ||
| //! \param dispatchedMaxExperts compile-time tier from queryDispatchedMaxExperts(), which | ||
| //! is not the model's raw expert count. | ||
| //! \param minNumExpertsForCoopOverride replaces the built-in Renormalize lower tier bound | ||
| //! when non-negative. 0 restores the parent behaviour of always preferring the | ||
| //! cooperative kernel; a value above every tier forces the classic kernel. It has | ||
| //! no effect on any other policy, which is not subject to the bound. | ||
| bool prefersCoopBlockKernel(RoutingPreprocessType preprocessType, RoutingPostprocessType postprocessType, | ||
| int32_t numTokens, int32_t dispatchedMaxExperts, int32_t minNumExpertsForCoopOverride = -1); | ||
|
|
||
| } // namespace moe::dev::routing::routingCustom |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.