-
Notifications
You must be signed in to change notification settings - Fork 25.6k
[aot autograd] refactor CompiledFunction.backward: prologue (1/N) #139331
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
Closed
Conversation
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
[ghstack-poisoned]
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/139331
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit c7ee4a0 with merge base a951d99 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
[ghstack-poisoned]
This was referenced Oct 30, 2024
…e (1/N)" [ghstack-poisoned]
zou3519
approved these changes
Oct 31, 2024
pytorchmergebot
pushed a commit
that referenced
this pull request
Oct 31, 2024
…39343) Pull Request resolved: #139343 Approved by: https://github.com/zou3519 ghstack dependencies: #139331
pytorchmergebot
pushed a commit
that referenced
this pull request
Oct 31, 2024
…#139347) Pull Request resolved: #139347 Approved by: https://github.com/zou3519 ghstack dependencies: #139331, #139343
rahulsingh-intel
pushed a commit
to rahulsingh-intel/pytorch
that referenced
this pull request
Nov 5, 2024
…torch#139331) So for functional autograd + CA, most nodes are inlined in aot autograd. But user-defined callables aren't safe to make_fx unless dynamo traces through them. The AOT backward must be inlined by dynamo time. We plan to directly insert calls to the backward in the graph: - call prologue - call bwd graph - call epilogue Restructuring our AOT bwd implementation will make this implementation easier. Pull Request resolved: pytorch#139331 Approved by: https://github.com/zou3519
rahulsingh-intel
pushed a commit
to rahulsingh-intel/pytorch
that referenced
this pull request
Nov 5, 2024
…torch#139343) Pull Request resolved: pytorch#139343 Approved by: https://github.com/zou3519 ghstack dependencies: pytorch#139331
rahulsingh-intel
pushed a commit
to rahulsingh-intel/pytorch
that referenced
this pull request
Nov 5, 2024
…pytorch#139347) Pull Request resolved: pytorch#139347 Approved by: https://github.com/zou3519 ghstack dependencies: pytorch#139331, pytorch#139343
This was referenced Nov 6, 2024
Closed
Esquains
pushed a commit
to Esquains/study1
that referenced
this pull request
Dec 15, 2024
ghstack-source-id: 4aa455f Pull Request resolved: pytorch/pytorch#139331
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.
So for functional autograd + CA, most nodes are inlined in aot autograd. But user-defined callables aren't safe to make_fx unless dynamo traces through them. The AOT backward must be inlined by dynamo time. We plan to directly insert calls to the backward in the graph:
Restructuring our AOT bwd implementation will make this implementation easier.
Stack from ghstack (oldest at bottom):