Skip to content

Arm backend: Fix Smollm2 model test#19812

Merged
gggekov merged 2 commits into
pytorch:mainfrom
gggekov:enable_testing_smollm2_ethosu
May 29, 2026
Merged

Arm backend: Fix Smollm2 model test#19812
gggekov merged 2 commits into
pytorch:mainfrom
gggekov:enable_testing_smollm2_ethosu

Conversation

@gggekov
Copy link
Copy Markdown
Collaborator

@gggekov gggekov commented May 27, 2026

  • Export & lower the smollm2 via extensions/llm/export_llm
  • Build the arm_executor_runner application
  • Fix the propagation of select_ops_list in the CMakeLists.txt
  • Test the application runs on FVP in fast mode

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

- Export & lower the smollm2 via extensions/llm/export_llm
- Build the arm_executor_runner application
- Fix the propagation of select_ops_list in the CMakeLists.txt
- Test the application runs on FVP in fast mode

Signed-off-by: George Gekov <george.gekov@arm.com>
Change-Id: I8acd87c2f5c3e6b5b189bb987ceccfe4877e2254
Copilot AI review requested due to automatic review settings May 27, 2026 16:48
@pytorch-bot
Copy link
Copy Markdown

pytorch-bot Bot commented May 27, 2026

🔗 Helpful Links

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

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

❗ 2 Active SEVs

There are 2 currently active SEVs. If your PR is affected, please view them below:

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 May 27, 2026
@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla Bot commented May 27, 2026

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: gggekov / name: George Gekov (d0401ab)

@gggekov gggekov added the partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm label May 27, 2026
@github-actions github-actions Bot added ciflow/trunk module: arm Issues related to arm backend and removed partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm labels May 27, 2026
@gggekov gggekov added partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm and removed module: arm Issues related to arm backend labels May 27, 2026
@github-actions
Copy link
Copy Markdown

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.

Copy link
Copy Markdown
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

This PR updates the Arm backend SmolLM2-135M test flow to export/lower via extension/llm/export_llm, build arm_executor_runner, and run on Corstone-320 FVP in fast mode, while also adjusting build scripts/CMake to better propagate selective-kernel configuration.

Changes:

  • Update SmolLM2-135M Arm backend test to export a PTE, build arm_executor_runner with PTE preloaded at a fixed DDR address, and run it on FVP fast mode.
  • Adjust arm_executor_runner CMake selective-oplist logic so user-provided EXECUTORCH_SELECT_OPS_LIST is not unconditionally cleared.
  • Minor robustness tweaks to Arm scripts (Ethos-U scratch derivation output handling; conditional forwarding of extra CMake args).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
examples/arm/run.sh Adjusts how Ethos-U scratch size is captured from PTE-derived output.
examples/arm/executor_runner/CMakeLists.txt Changes selective-oplist propagation behavior for kernel registration.
backends/arm/test/test_arm_backend.sh Reworks SmolLM2-135M test into export → build runner → FVP execution flow.
backends/arm/scripts/build_executorch.sh Only appends extra CMake args when provided.
Comments suppressed due to low confidence (1)

examples/arm/executor_runner/CMakeLists.txt:356

  • The else() branch no longer clears EXECUTORCH_SELECT_OPS_LIST, which can unintentionally keep a default or previously set list (e.g., from run.sh) even when the PTE has no undelegated ops. This contradicts the comment above (“If the pte contains no undelegated ops, use neither.”) and may register/build extra kernels unnecessarily. Consider only preserving the list for the ET_MODEL_PTE_ADDR flow (where auto-gen from model isn’t possible), and clearing it otherwise.
else()
  set(EXECUTORCH_SELECT_OPS_MODEL "")
  message(
    "gen_oplist: No non delagated ops was found in ${ET_PTE_FILE_PATH} no ops added to build"
  )
endif()

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

Comment thread backends/arm/test/test_arm_backend.sh Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 29, 2026 10:15
@github-actions github-actions Bot added the module: arm Issues related to arm backend label May 29, 2026
Copy link
Copy Markdown
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

Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (1)

examples/arm/executor_runner/CMakeLists.txt:355

  • In the else() branch, EXECUTORCH_SELECT_OPS_LIST is no longer cleared (which is needed to allow a user-provided list to propagate), but the log message still claims that no ops will be added. Also fix the typo "delagated" → "delegated". Consider making the message conditional on whether EXECUTORCH_SELECT_OPS_LIST is empty so the build output matches actual behavior.
else()
  set(EXECUTORCH_SELECT_OPS_MODEL "")
  message(
    "gen_oplist: No non delagated ops was found in ${ET_PTE_FILE_PATH} no ops added to build"
  )

@gggekov gggekov merged commit b0441b5 into pytorch:main May 29, 2026
447 of 461 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. module: arm Issues related to arm backend partner: arm For backend delegation, kernels, demo, etc. from the 3rd-party partner, Arm

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants