Skip to content

Cortex_M backend: Improve PatternMatcher algorithm#17776

Merged
AdrianLundell merged 3 commits intopytorch:mainfrom
AdrianLundell:change-1206720
Mar 3, 2026
Merged

Cortex_M backend: Improve PatternMatcher algorithm#17776
AdrianLundell merged 3 commits intopytorch:mainfrom
AdrianLundell:change-1206720

Conversation

@AdrianLundell
Copy link
Collaborator

@AdrianLundell AdrianLundell commented Mar 2, 2026

The previous algorithm failed for cases where a pattern matched outside of the nodes given by the node iterator.

Update to a queue based algorithm to keep the function as a generator and add testing of this case.

Additionally do not quantize operators with very large inputs and remove unused filter_fn for filtering out nodes.

cc @digantdesai @SS-JIA @freddan80 @per @zingo @oscarandersson8218 @mansnils @Sebastian-Larsson @robell

The previous algorithm failed for cases where a pattern
matched outside of the nodes given by the node iterator.

Update to a queue based algorithm to keep the function as a generator
and add testing of this case.

Additionally do not quantize operators with very large inputs and
remove unused filter_fn for filtering out nodes.

Signed-off-by: Adrian Lundell <adrian.lundell@arm.com>
Change-Id: Idbbd6e0261d9e31f3b64ee1c229cc626c42ad435
@AdrianLundell AdrianLundell requested a review from psiddh March 2, 2026 09:15
@AdrianLundell AdrianLundell requested a review from rascani as a code owner March 2, 2026 09:15
@AdrianLundell AdrianLundell added partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm ciflow/trunk release notes: none Do not include this in the release notes labels Mar 2, 2026
@pytorch-bot
Copy link

pytorch-bot bot commented Mar 2, 2026

🔗 Helpful Links

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

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

❌ 4 New Failures, 2 Unrelated Failures

As of commit c83699d with merge base 0d010de (image):

NEW FAILURES - The following jobs have 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.

@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 Mar 2, 2026
AdrianLundell and others added 2 commits March 3, 2026 11:57
Signed-off-by: Adrian Lundell <adrian.lundell@arm.com>
Change-Id: I6f02769379a5e58471994a7bd2f79084c89d0881
@AdrianLundell AdrianLundell merged commit fd47647 into pytorch:main Mar 3, 2026
311 of 317 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/trunk CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm release notes: none Do not include this in the release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants