-
Notifications
You must be signed in to change notification settings - Fork 821
Allow for matching debug handles with partial overlap between aten graph and runtime #14306
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
Allow for matching debug handles with partial overlap between aten graph and runtime #14306
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/14306
Note: Links to docs will display an error until the docs builds have been completed. ❌ 3 New Failures, 1 Unrelated FailureAs of commit acbf935 with merge base 0f066e0 ( NEW FAILURES - The following jobs have failed:
BROKEN TRUNK - The following job failed but were present on the merge base:👉 Rebase onto the `viable/strict` branch to avoid these failures
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
@kimishpatel has exported this pull request. If you are a Meta employee, you can view the originating diff in D82229367. |
This PR needs a
|
…aph and runtime (pytorch#14306) Summary: When aten graph is modified for debug, for instance using int4 matmul, it wont have complete overlap with debug handles recorded by the delegate. For example, original model will have chose_qparams,q, dq, dq, linear nodes. Delegate will record debug hanlde for all of those. Say those are (4, 5, 6, 7, 8). When int4 matmul rewrite pass, from torchao, is applied, we just inherit from_node information from linear node. Thus only the last debug handle 8 is associated with custom op int4 node. Thus when we map delegate debug handles with custom op we find overlap for 8 only. This diff allows to look for overlapping match instead of exact match. Plus it also changes the code for AOT debug handle so that we can look for all ancestor nodes instead of just parent node. This is also needed so as to allow for numerical comparison despite passes applied on original aten graph. Reviewed By: Gasoonjia Differential Revision: D82229367
6b7115e to
acbf935
Compare
|
@kimishpatel has exported this pull request. If you are a Meta employee, you can view the originating diff in D82229367. |
…aph and runtime Differential Revision: D82229367 Pull Request resolved: pytorch#14306
…aph and runtime Differential Revision: D82229367 Pull Request resolved: pytorch#14306
Summary:
When aten graph is modified for debug, for instance using int4 matmul, it wont have complete
overlap with debug handles recorded by the delegate. For example, original model will have
chose_qparams,q, dq, dq, linear nodes. Delegate will record debug hanlde for all of those.
Say those are (4, 5, 6, 7, 8). When int4 matmul rewrite pass, from torchao, is applied,
we just inherit from_node information from linear node. Thus only the last debug handle 8
is associated with custom op int4 node. Thus when we map delegate debug handles with custom op
we find overlap for 8 only.
This diff allows to look for overlapping match instead of exact match.
Plus it also changes the code for AOT debug handle so that we can look for all ancestor nodes
instead of just parent node. This is also needed so as to allow for numerical comparison despite
passes applied on original aten graph.
Reviewed By: Gasoonjia
Differential Revision: D82229367