Skip to content

Arm backend: Use reshape instead of view before edge - #15269

Merged
Sebastian-Larsson merged 6 commits into
pytorch:mainfrom
Erik-Lundell:expand-copy
Oct 24, 2025
Merged

Sebastian-Larsson merged 6 commits into
pytorch:mainfrom
Erik-Lundell:expand-copy

Conversation

@Erik-Lundell

@Erik-Lundell Erik-Lundell commented Oct 20, 2025 •

Copy link
Copy Markdown
Collaborator

The view operator can't handle non-contigious strides, such as the result of an expand. These are normalized after to_edge, but in the transform_for_annotation_pipeline we shouldn't use views for that reason.
Reshape is the equivalent operator that can handle such strides.

cc @freddan80 @per @zingo @oscarandersson8218 @digantdesai

The view operator can't handle non-contigious strides,
such as the result of an expand. These are normalized
after to_edge, but in the transform_for_annotation_pipeline
we shouldn't use views for that reason.
Reshape is the equivalent operator that can handle such strides.

This issue was found in the roberta model.

Signed-off-by: Erik Lundell <[email protected]>
Change-Id: I042b76ecf8b99e4e65bf951c00ec53a9d0d36c80
@pytorch-bot

pytorch-bot Bot commented Oct 20, 2025 •

Copy link
Copy Markdown

🔗 Helpful Links

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

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

❌ 10 New Failures, 3 Unrelated Failures

As of commit 1354c37 with merge base b24c39a (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 Oct 20, 2025
@Erik-Lundell Erik-Lundell 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 and removed CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. labels Oct 20, 2025
@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 Oct 20, 2025

@Sebastian-Larsson Sebastian-Larsson left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated CI failures

@Sebastian-Larsson
Sebastian-Larsson merged commit 69f79b9 into pytorch:main Oct 24, 2025
GregoryComer added a commit to GregoryComer/executorch that referenced this pull request Oct 27, 2025
jirioc pushed a commit to nxp-upstream/executorch that referenced this pull request Dec 19, 2025
The view operator can't handle non-contigious strides, such as the
result of an expand. These are normalized after to_edge, but in the
transform_for_annotation_pipeline we shouldn't use views for that
reason.
Reshape is the equivalent operator that can handle such strides.

Signed-off-by: Erik Lundell <[email protected]>
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.

2 participants