-
Notifications
You must be signed in to change notification settings - Fork 26.3k
[quant] Add QuantFusion to graph_executor #26331
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
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]
| // Rewrite subgraphs with many MMs into expressions that batch them. | ||
| BatchMM(graph); | ||
|
|
||
| if (at::globalContext().qEngine() == at::kFBGEMM || |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Where should we put this then?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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?
Stack from ghstack:
Summary:
att
Test Plan:
.
Reviewers:
pt1quant
Subscribers:
Tasks:
Tags:
Differential Revision: D17464905