Skip to content

Cortex-M: keep NHWC channel broadcasts quantized - #21968

Draft
rascani wants to merge 8 commits into
gh/rascani/13/headfrom
gh/rascani/14/head
Draft

Cortex-M: keep NHWC channel broadcasts quantized#21968
rascani wants to merge 8 commits into
gh/rascani/13/headfrom
gh/rascani/14/head

Conversation

@rascani

@rascani rascani commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Keep channel-broadcast add and multiply in int8 when supported explicit-layout
anchors are reachable on both sides, including through activation patterns fused
before layout formation.

Derive the anchor set from the explicit operator map and terminate only the
affected region edge at backend barriers. Validate that every annotated
unequal-shape operation became a channel broadcast the kernels can serve as a
flat repeat before runtime lowering.

Without this an SE-shaped block leaves its multiply as an unquantized aten
operator and splits the layout region, doubling the boundary transposes.

Local Corstone-300 run of the full Cortex-M suite and lintrunner.

Authored with Codex.

[ghstack-poisoned]
@pytorch-bot

pytorch-bot Bot commented Aug 20, 2026

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/21968

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 New Failure, 6 Unrelated Failures

As of commit c76dcc1 with merge base 8b93850 (image):

NEW FAILURE - The following job has failed:

BROKEN TRUNK - The following jobs 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.

[ghstack-poisoned]
rascani added a commit that referenced this pull request Aug 20, 2026
Keep channel-broadcast add and multiply in int8 when supported explicit-layout anchors are reachable on both sides, including through activation patterns fused before layout formation.

Derive the anchor set from the explicit operator map, lower accepted broadcasts to fixed quantized_add_nhwc and quantized_mul_nhwc schemas, and terminate only the affected region edge at backend barriers. Validate that every annotated unequal-shape operation became a logical-NHWC channel broadcast before runtime lowering.

16 host tests, 116 combined Buck tests, ten Cortex-M55 FVP cases, Cortex-M33 add and multiply execution, planned-memory parity for the branched broadcast case, and lintrunner.

Authored with Codex.


ghstack-source-id: 8837467
ghstack-comment-id: 5351512448
Pull-Request: #21968
@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Aug 20, 2026
[ghstack-poisoned]
rascani added a commit that referenced this pull request Aug 20, 2026
Keep channel-broadcast add and multiply in int8 when supported explicit-layout anchors are reachable on both sides, including through activation patterns fused before layout formation.

Derive the anchor set from the explicit operator map, lower accepted broadcasts to fixed quantized_add_nhwc and quantized_mul_nhwc schemas, and terminate only the affected region edge at backend barriers. Validate that every annotated unequal-shape operation became a logical-NHWC channel broadcast before runtime lowering.

16 host tests, 116 combined Buck tests, ten Cortex-M55 FVP cases, Cortex-M33 add and multiply execution, planned-memory parity for the branched broadcast case, and lintrunner.

Authored with Codex.


ghstack-source-id: a55287a
ghstack-comment-id: 5351512448
Pull-Request: #21968
[ghstack-poisoned]
rascani added a commit that referenced this pull request Aug 21, 2026
Keep channel-broadcast add and multiply in int8 when supported explicit-layout
anchors are reachable on both sides, including through activation patterns fused
before layout formation.

Derive the anchor set from the explicit operator map and terminate only the
affected region edge at backend barriers. Validate that every annotated
unequal-shape operation became a channel broadcast the kernels can serve as a
flat repeat before runtime lowering.

Without this an SE-shaped block leaves its multiply as an unquantized aten
operator and splits the layout region, doubling the boundary transposes.

Local Corstone-300 run of the full Cortex-M suite and lintrunner.

Authored with Codex.

ghstack-source-id: c632891
ghstack-comment-id: 5351512448
Pull-Request: #21968
rascani added a commit that referenced this pull request Aug 21, 2026
Keep channel-broadcast add and multiply in int8 when supported explicit-layout
anchors are reachable on both sides, including through activation patterns fused
before layout formation.

Derive the anchor set from the explicit operator map and terminate only the
affected region edge at backend barriers. Validate that every annotated
unequal-shape operation became a channel broadcast the kernels can serve as a
flat repeat before runtime lowering.

Without this an SE-shaped block leaves its multiply as an unquantized aten
operator and splits the layout region, doubling the boundary transposes.

Local Corstone-300 run of the full Cortex-M suite and lintrunner.

Authored with Codex.

ghstack-source-id: c632891
ghstack-comment-id: 5351512448
Pull-Request: #21968
[ghstack-poisoned]
rascani added a commit that referenced this pull request Aug 21, 2026
Keep channel-broadcast add and multiply in int8 when supported explicit-layout
anchors are reachable on both sides, including through activation patterns fused
before layout formation.

Derive the anchor set from the explicit operator map and terminate only the
affected region edge at backend barriers. Validate that every annotated
unequal-shape operation became a channel broadcast the kernels can serve as a
flat repeat before runtime lowering.

Without this an SE-shaped block leaves its multiply as an unquantized aten
operator and splits the layout region, doubling the boundary transposes.

Local Corstone-300 run of the full Cortex-M suite and lintrunner.

Authored with Codex.

ghstack-source-id: 8a1d7ef
ghstack-comment-id: 5351512448
Pull-Request: #21968
[ghstack-poisoned]
[ghstack-poisoned]
[ghstack-poisoned]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant