You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Promote NXP redundant Q/DQ cleanup to to_edge (#22913)
Eval-mode dropout can disappear before shared no-op cleanup runs,
leaving adjacent dequantize/quantize conversions. Promote NXP's
`FoldRedundantDequantizeQuantizePass` from #21016 into the shared
lowering sequence used by `to_edge` and `to_edge_transform_and_lower`.
Cortex-M MLPerf Tiny DS-CNN then finishes with one quantize and one
dequantize operation in both layouts, down from three of each.
MobileNetV2 similarly drops from two to one of each.
The shared `eliminate_dq_q` matcher remains unchanged, keeping this
release patch focused on promoting the existing cleanup. Remove the
stale dropout target from `RemoveNoopPass`. NXP retains a later
invocation of the shared pass because its auxiliary-operator splitting
can introduce new adjacent pairs. Update the Cortex-M model counts and
correct the clone regression's obsolete Q/DQ signatures so the test also
checks numerical equivalence.
Validation on PyTorch 2.14 CPU: 77 EXIR and clone-transform tests
passed, with 28 passing subtests and one expected failure. The dropout
regression covers both edge APIs, per-tensor and per-channel
quantization, and int8/uint8/int16/int32. All 25 selected Cortex-M
DS-CNN, MobileNetV2, and explicit-layout tests passed, including
Corstone-300 FVP implementation tests. Additional explicit-layout DS-CNN
and legacy `ExirExportedProgram.to_edge` numerical checks passed.
Formatting, flake8, and `git diff --check` passed.
Authored with AI assistance from OpenAI Codex.
Co-authored-by: RJ Ascani <rja@meta.com>
0 commit comments