Add flag to fx.passes.split_module to normalize input names#157793
Merged
atalman merged 1 commit intorelease/2.8from Jul 16, 2025
Merged
Add flag to fx.passes.split_module to normalize input names#157793atalman merged 1 commit intorelease/2.8from
atalman merged 1 commit intorelease/2.8from
Conversation
This is useful for vLLM, which runs AOTAutograd directly on graphs after they have been split. I created a new flag for this instead of reusing `keep_original_node_name` (please let me know if you think I should reuse this). The reasoning is: - The names of the placeholder nodes is different from the targets of the placehoder nodes. The targets are the actual input names. - Backwards compatibility: this API has been out for ~4 years, it looks public, and it has extensive public use. For example, this change would actually be BC-breaking to vLLM (they rely on the subgraph input names being different at the moment). Test Plan: - new tests Pull Request resolved: #157733 Approved by: https://github.com/ezyang (cherry picked from commit b9afdd9)
This was referenced Jul 8, 2025
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/157793
Note: Links to docs will display an error until the docs builds have been completed. ✅ You can merge normally! (1 Unrelated Failure)As of commit e6a07f4 with merge base 3a7ff82 ( UNSTABLE - The following job is marked as unstable, possibly due to flakiness on trunk:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
79 tasks
Contributor
|
Validated tests on release/2.8 |
tvukovic-amd
pushed a commit
to ROCm/pytorch
that referenced
this pull request
Aug 20, 2025
…157793) Add flag to fx.passes.split_module to normalize input names (pytorch#157733) This is useful for vLLM, which runs AOTAutograd directly on graphs after they have been split. I created a new flag for this instead of reusing `keep_original_node_name` (please let me know if you think I should reuse this). The reasoning is: - The names of the placeholder nodes is different from the targets of the placehoder nodes. The targets are the actual input names. - Backwards compatibility: this API has been out for ~4 years, it looks public, and it has extensive public use. For example, this change would actually be BC-breaking to vLLM (they rely on the subgraph input names being different at the moment). Test Plan: - new tests Pull Request resolved: pytorch#157733 Approved by: https://github.com/ezyang (cherry picked from commit b9afdd9) Co-authored-by: rzou <zou3519@gmail.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.
Stack from ghstack (oldest at bottom):
This is useful for vLLM, which runs AOTAutograd directly on graphs after
they have been split.
I created a new flag for this instead of reusing
keep_original_node_name(please let me know if you think I should reuse this).The reasoning is:
the placehoder nodes. The targets are the actual input names.
looks public, and it has extensive public use. For example, this change
would actually be BC-breaking to vLLM (they rely on the subgraph input
names being different at the moment).
Test Plan:
cc @ezyang @SherlockNoMad @EikanWang @jgong5 @wenzhe-nrv