Allow parameterless FSDP root modules - #5711
Merged
Merged
Conversation
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
wujingyue
marked this pull request as ready for review
July 8, 2026 17:55
wujingyue
force-pushed
the
fsdp-empty-root
branch
from
July 9, 2026 20:45
bb4de87 to
e7a665b
Compare
Signed-off-by: Jingyue Wu <jingyuew@nvidia.com>
wujingyue
force-pushed
the
fsdp-empty-root
branch
from
July 9, 2026 20:49
e7a665b to
3a61d62
Compare
Autumn1998
approved these changes
Jul 13, 2026
Signed-off-by: Jingyue Wu <jingyuew@nvidia.com>
jiemingz
approved these changes
Jul 13, 2026
yaoyu-33
approved these changes
Jul 17, 2026
Signed-off-by: Jingyue Wu <jingyuew@nvidia.com> # Conflicts: # megatron/core/distributed/fsdp/src/megatron_fsdp/experimental/module.py
wujingyue
enabled auto-merge
July 17, 2026 03:00
Contributor
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA/Megatron-LM/actions/runs/29555614995 |
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Jul 17, 2026
Contributor
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA/Megatron-LM/actions/runs/29560018176 |
chochowski
pushed a commit
to chochowski/Megatron-LM
that referenced
this pull request
Jul 20, 2026
Signed-off-by: Jingyue Wu <jingyuew@nvidia.com> Signed-off-by: mchochowski <mchochowski@nvidia.com>
terminator123
pushed a commit
to 021ai/Megatron-LM
that referenced
this pull request
Aug 3, 2026
Signed-off-by: Jingyue Wu <jingyuew@nvidia.com>
svcnvidia-nemo-ci
pushed a commit
to dimapihtar/Megatron-LM
that referenced
this pull request
Aug 4, 2026
Signed-off-by: Jingyue Wu <jingyuew@nvidia.com> Signed-off-by: Dmytro Pykhtar <dpykhtar@nvidia.com>
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.
Summary
Why
FSDP overlap coordination is scoped within a root FSDP module, matching the PyTorch FSDP2 model. That means users and tests will often wrap higher-level container modules to define the root scope, even when all real parameters are already owned by child FSDP units.
The rejected-empty-parameter check was originally added as a sanity check. With root-scoped overlap, that sanity check is too restrictive: an empty root can be a valid container for child FSDP units. Allowing it avoids forcing artificial root-owned parameters just to establish that scope, which keeps unit tests simpler and makes the expected higher-level wrapping pattern work naturally.
Testing