fix: warmup uses full token budget for DP#1024
Open
ZhangLirong-amd wants to merge 1 commit into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates model warmup behavior so it exercises the full configured batch token budget (max_num_batched_tokens) rather than scaling it down by data-parallel size, aiming to better match peak activation / CUDA-graph memory seen during real DP-attention decode workloads.
Changes:
- Set
warmup_max_tokenstomax_num_batched_tokens(no longer divided bydp_size). - Update the warmup warning message to reflect the new sizing behavior.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+1069
to
1071
| f"{self.label}: warmup_max_tokens={warmup_max_tokens} (=max_num_batched_tokens) " | ||
| f"< max_model_len={max_model_len}. " | ||
| f"Using {num_seqs} seq with length {seq_len} for warmup." |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Warmup now uses the full
max_num_batched_tokensinstead of dividing bydp_size. Under DP attention each rank's MoE sees up todp_size * local_tokensafter the all-gather, so warmup must exercise the full token budget to capture the true peak activation / CUDA-graph footprint; dividing by dp_size under-sized warmup and let decode OOM later. Also updated the warning message accordingly.