Skip to content

Fix broken tests #8888

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

Merged
merged 1 commit into from
Mar 4, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions exir/program/_program.py
Original file line number Diff line number Diff line change
Expand Up @@ -978,6 +978,18 @@ def _remove_invalid_ops_for_not_decompose(
) -> List[torch._ops.OpOverload]:
# To address https://github.com/pytorch/executorch/issues/8781
def keep(op):
# Explicit allow list
allow_list = []
try:
# Ops in torch.ops.quant are not always loaded, so we use try/except
# Aliases output, but we need to allow it for XNNPACK
allow_list.append(torch.ops.quant.choose_qparams_affine.default)
except:
pass

if op in allow_list:
return True

schema = op._schema
native_schema = _pybind_schema_to_native_schema(schema)
if native_schema.is_mutable:
Expand Down
Loading