[quant] Add QuantFusion to graph_executor#26331
Merged
jerryzh168 merged 6 commits intogh/jerryzh168/70/basefrom Sep 20, 2019
Merged
[quant] Add QuantFusion to graph_executor#26331jerryzh168 merged 6 commits intogh/jerryzh168/70/basefrom
jerryzh168 merged 6 commits intogh/jerryzh168/70/basefrom
Conversation
Summary: att Test Plan: . Reviewers: pt1quant Subscribers: Tasks: Tags: [ghstack-poisoned]
Summary: att Test Plan: . Reviewers: pt1quant Subscribers: Tasks: Tags: [ghstack-poisoned]
Summary: att Test Plan: . Reviewers: pt1quant Subscribers: Tasks: Tags: [ghstack-poisoned]
Summary: att Test Plan: . Reviewers: pt1quant Subscribers: Tasks: Tags: [ghstack-poisoned]
Summary: att Test Plan: . Reviewers: pt1quant Subscribers: Tasks: Tags: [ghstack-poisoned]
Summary: att Test Plan: . Reviewers: pt1quant Subscribers: Tasks: Tags: Differential Revision: [D17464905](https://our.internmc.facebook.com/intern/diff/D17464905) [ghstack-poisoned]
zdevito
requested changes
Sep 19, 2019
| // Rewrite subgraphs with many MMs into expressions that batch them. | ||
| BatchMM(graph); | ||
|
|
||
| if (at::globalContext().qEngine() == at::kFBGEMM || |
Contributor
There was a problem hiding this comment.
What happens if the qEngine is changed between when the code is compiled and when it is run? This seems suspicious. The GraphExecutor has no mechanism to invalidate compilation state and shouldn't grow such a mechanism.
Contributor
Author
There was a problem hiding this comment.
Where should we put this then?
There was a problem hiding this comment.
I think we should not be allowed to change qEngine on the fly. I think it's reasonable to be able to retrieve info about target we're running at and specializing for, and context seems to be fitting that well. However, the context should not be mutable in this scheme. @zdevito, does that make sense to you?
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:
Summary:
att
Test Plan:
.
Reviewers:
pt1quant
Subscribers:
Tasks:
Tags:
Differential Revision: D17464905