Remove generated_unboxing_wrappers and setManuallyBoxedKernel#49251
Closed
smessmer wants to merge 38 commits intogh/smessmer/288/basefrom
Closed
Remove generated_unboxing_wrappers and setManuallyBoxedKernel#49251smessmer wants to merge 38 commits intogh/smessmer/288/basefrom
smessmer wants to merge 38 commits intogh/smessmer/288/basefrom
Conversation
Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
This was referenced Dec 11, 2020
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
ezyang
approved these changes
Jan 4, 2021
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
bhosmer
approved these changes
Jan 6, 2021
| } | ||
| TORCH_INTERNAL_ASSERT(boxed_kernel_func_ == nullptr, "Tried to set a manually boxed kernel for a kernel that already has a boxed kernel set."); | ||
| TORCH_INTERNAL_ASSERT(unboxed_kernel_func_ != nullptr, "Tried to set a manually boxed kernel for an invalid KernelFunction."); | ||
| boxed_kernel_func_ = func; |
There was a problem hiding this comment.
IIRC this is the only place boxed_kernel_func_ was ever updated after construction, can it now be a const member?
Contributor
Author
There was a problem hiding this comment.
maybe if we remove the assignment operator from KernelFunction. But currently, that operator implicitly exists and is used in some call sites.
…nel" Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. Differential Revision: [D25502865](https://our.internmc.facebook.com/intern/diff/D25502865/) **NOTE FOR REVIEWERS**: This PR has internal Facebook specific changes or comments, please review them on [Phabricator](https://our.internmc.facebook.com/intern/diff/D25502865/)! [ghstack-poisoned]
Contributor
|
This pull request has been merged in 249261a. |
hwangdeyu
pushed a commit
to hwangdeyu/pytorch
that referenced
this pull request
Jan 14, 2021
…h#49251) Summary: Pull Request resolved: pytorch#49251 Since all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore. Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher. ghstack-source-id: 119450486 Test Plan: waitforsandcastle Reviewed By: ezyang Differential Revision: D25502865 fbshipit-source-id: 49d009df159fda4be41bd02457d4427e6e638c10
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:
use_c10_dispatcher: fulllines #49259 Removeuse_c10_dispatcher: fulllinesSince all ops are c10-full and use templated unboxing now, we don't need to codegenerate any unboxing logic anymore.
Since this codegen was the only code using setManuallyBoxedKernel, we can also remove that functionality from KernelFunction, OperatorEntry and Dispatcher.
Differential Revision: D25502865
NOTE FOR REVIEWERS: This PR has internal Facebook specific changes or comments, please review them on Phabricator!