Skip to content

Cortex m e2e#18311

Draft
psiddh wants to merge 1 commit intomainfrom
cortex_m_e2e
Draft

Cortex m e2e#18311
psiddh wants to merge 1 commit intomainfrom
cortex_m_e2e

Conversation

@psiddh
Copy link
Contributor

@psiddh psiddh commented Mar 19, 2026

No description provided.

@psiddh psiddh requested a review from rascani as a code owner March 19, 2026 07:13
Copilot AI review requested due to automatic review settings March 19, 2026 07:13
@pytorch-bot
Copy link

pytorch-bot bot commented Mar 19, 2026

🔗 Helpful Links

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

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

❌ 5 New Failures, 1 Cancelled Job, 3 Unrelated Failures

As of commit 7107178 with merge base 569cf41 (image):

NEW FAILURES - The following jobs have failed:

CANCELLED JOB - The following job was cancelled. Please retry:

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 19, 2026
@github-actions
Copy link

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

Add a CI job that exports models (mv2, mv3) via aot_arm_compiler.py
with --target=cortex-m55+int8 and runs them on the Corstone-300 FVP.
Uses matrix strategy so adding models is just appending to the list.

- New .ci/scripts/test_cortex_m_e2e.sh: export + FVP runner script
- Enable --bundleio in build_test_runner.sh for .bpte support
- Add test-cortex-m-e2e job to trunk.yml

Authored with Claude.
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds Cortex‑M backend test coverage and introduces a trunk CI end‑to‑end flow that exports selected models as BundleIO .bpte and runs them on Corstone‑300 FVP.

Changes:

  • Add new Cortex‑M model tests covering common torch op patterns, nn.Module compositions, and torch.nn.functional usage.
  • Update Cortex‑M test runner build to enable BundleIO support.
  • Replace the existing trunk Cortex‑M test job with a new matrix e2e job (mv2/mv3) that exports via examples.arm.aot_arm_compiler and runs on FVP.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
backends/cortex_m/test/models/test_torch_functions.py New composite-model dialect tests for common torch patterns through Cortex‑M pipeline.
backends/cortex_m/test/models/test_nn_modules.py New dialect tests for popular nn.Module blocks (with one xfail).
backends/cortex_m/test/models/test_nn_functional.py New dialect tests for common torch.nn.functional patterns.
backends/cortex_m/test/build_test_runner.sh Build semihosting runner with --bundleio enabled.
.github/workflows/trunk.yml Introduce test-cortex-m-e2e matrix job and switch trunk Cortex‑M coverage to e2e invocation.
.github/workflows/pull.yml Add a PR-only job that runs Cortex‑M pytest suite.
.ci/scripts/test_cortex_m_e2e.sh New script exporting .bpte and running it on Corstone‑300 FVP.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

# To build cortex-m test runner
# Build cortex-m test runner with bundled IO support
backends/cortex_m/test/build_test_runner.sh

ramp_tensor,
)

torch.manual_seed(0)
Comment on lines +34 to +36
torch.manual_seed(0)


ramp_tensor,
)

torch.manual_seed(0)
Comment on lines +39 to +48
echo "=== Running ${MODEL} on Corstone-300 FVP ==="
FVP_Corstone_SSE-300_Ethos-U55 \
-C ethosu.num_macs=128 \
-C mps3_board.visualisation.disable-visualisation=1 \
-C cpu0.semihosting-enable=1 \
-C "cpu0.semihosting-cwd=${WORK_DIR}" \
-C "ethosu.extra_args='--fast'" \
-C "cpu0.semihosting-cmd_line='executor_runner -m ${MODEL}.bpte'" \
-a "${ELF}" \
--timelimit 300
@psiddh psiddh marked this pull request as draft March 19, 2026 07:21
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.

2 participants