Skip to content
Closed

Test fix #10423

Show file tree
Hide file tree
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
1 change: 0 additions & 1 deletion exir/TARGETS
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ python_library(
"//caffe2:torch",
"//executorch/exir/operator:convert",
"//executorch/extension/pytree:pylib",
"//pytorch/ao:torchao",
],
)

Expand Down
16 changes: 0 additions & 16 deletions exir/tracer.py
Original file line number Diff line number Diff line change
Expand Up @@ -643,22 +643,6 @@ def _default_decomposition_table(
# pyre-fixme[7]: Expected `Dict[OpOverload, typing.Callable[..., executorch.exir....

never_decompose = []
try:
# Do not decompose torchao quant primitives
# They have decompositions registered for inductor/CUDA, but in ExecuTorch we
# just pattern match them and lower to delegates
import torchao # noqa: F401

never_decompose.extend(
[
torch.ops.torchao.quantize_affine.default,
torch.ops.torchao.dequantize_affine.default,
torch.ops.torchao.choose_qparams_affine.default,
]
)
except:
pass

for op in never_decompose:
decomps.pop(op, None)
return decomps # pyre-fixme[7]
Expand Down
Loading