Allow context-binary lowering to use edge dialect ops (#20518)#20518
Allow context-binary lowering to use edge dialect ops (#20518)#20518JakeStevens wants to merge 1 commit into
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/20518
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit db9263c with merge base 7013c8d ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
@JakeStevens has exported this pull request. If you are a Meta employee, you can view the originating Diff in D109598309. |
This PR needs a
|
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. Loader detection now goes through a single `is_context_loader_target()` helper that matches the op namespace (so it works on the edge-dialect wrapper), replacing the three name-dependent checks (`eval`, raw `.namespace`, substring). Differential Revision: D109598309
ce774b0 to
101ea39
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. Loader detection now goes through a single `is_context_loader_target()` helper that matches the op namespace (so it works on the edge-dialect wrapper), replacing the three name-dependent checks (`eval`, raw `.namespace`, substring). Differential Revision: D109598309
101ea39 to
e924d07
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. Loader detection now goes through a single `is_context_loader_target()` helper that matches the op namespace (so it works on the edge-dialect wrapper), replacing the three name-dependent checks (`eval`, raw `.namespace`, substring). Differential Revision: D109598309
e924d07 to
1095873
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. Loader detection now goes through a single `is_context_loader_target()` helper that matches the op namespace (so it works on the edge-dialect wrapper), replacing the three name-dependent checks (`eval`, raw `.namespace`, substring). Differential Revision: D109598309
1095873 to
18d165e
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. Loader detection now goes through a single `is_context_loader_target()` helper that matches the op namespace (so it works on the edge-dialect wrapper), replacing the three name-dependent checks (`eval`, raw `.namespace`, substring). Differential Revision: D109598309
18d165e to
36aeffe
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. Loader detection now goes through a single `is_context_loader_target()` helper that matches the op namespace (so it works on the edge-dialect wrapper), replacing the three name-dependent checks (`eval`, raw `.namespace`, substring). Differential Revision: D109598309
36aeffe to
9daf0b4
Compare
4a7dc4d to
47831a9
Compare
|
I have updated the PR to the minimal changes:
|
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
47831a9 to
598986e
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
598986e to
d537d1c
Compare
Summary: Pull Request resolved: pytorch#20518 Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
d537d1c to
7346a6a
Compare
Summary: Pull Request resolved: pytorch#20518 Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
7346a6a to
87430f4
Compare
87430f4 to
21d5519
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
Summary: Pull Request resolved: pytorch#20518 Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
21d5519 to
8b08c87
Compare
|
@claude review this pr |
|
Claude finished @psiddh's task in 3m 13s —— View job Code Review: PR #20518 — Allow context-binary lowering to use edge dialect ops
Overall this is a clean, well-scoped change. Dropping the Correctness — looks good ✅The key concern with
Minor observations
Test coverage — good
Note re:
|
Can you add more context on why this is needed or what usecase is enabled with this change |
_use_edge_ops is being deprecated, this instance is the last remaining (in-tree) usage of _use_edge_ops=False. Once this is removed, we can finally deprecate. See the TODO here: https://github.com/pytorch/executorch/blob/main/exir/capture/_config.py |
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
8b08c87 to
b249858
Compare
Summary: Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
Summary: Pull Request resolved: pytorch#20518 Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
b3fde42 to
e39dbfd
Compare
|
Addressed claude review |
Summary: Pull Request resolved: pytorch#20518 Unblocks the QNN context-binary path from lowering through `to_edge` with `_use_edge_ops=True` (the default). Previously it was pinned to `EdgeCompileConfig(_use_edge_ops=False)` purely to keep the `qaisw` context-loader custom op's original name, because loader detection was name-based. We can simply unwrap the op overload and maintain the same check. Differential Revision: D109598309
e39dbfd to
db9263c
Compare
|
@harshs-qti @shewu-quic are there any specific concerns you have or additional tests I can run? |
Summary:
Unblocks the QNN context-binary path from lowering through
to_edgewith_use_edge_ops=True(the default). Previously it was pinned toEdgeCompileConfig(_use_edge_ops=False)purely to keep theqaiswcontext-loader custom op's original name, because loader detection was name-based.We can simply unwrap the op overload and maintain the same check.
Differential Revision: D109598309