Add Pico2 build validation CI (trunk only)#18900
Conversation
Adds two parallel CI jobs that validate FP32 and CMSIS-NN INT8 Pico2 firmware builds on every push to main. Each job exports a model, cross- compiles firmware, and validates the .elf/.uf2 artifacts fit within Pico2 memory limits (520KB SRAM, 4MB flash). Triggered on push to main when examples/raspberry_pi/pico2/** or backends/cortex_m/** files change, plus a daily schedule. Co-authored-by: Claude <noreply@anthropic.com>
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/18900
Note: Links to docs will display an error until the docs builds have been completed. ❌ 3 New Failures, 2 Pending, 1 Unrelated FailureAs of commit 0ee15b8 with merge base 26e2ab8 ( NEW FAILURES - The following jobs have failed:
BROKEN TRUNK - The following job 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. |
This PR needs a
|
There was a problem hiding this comment.
Pull request overview
Adds a new GitHub Actions workflow to continuously validate Raspberry Pi Pico2 firmware builds (FP32 and CMSIS-NN INT8), including artifact existence checks and basic memory-size guardrails, to catch regressions from changes in the Pico2 example or Cortex-M backend.
Changes:
- Introduces a new
test-pico2-build.ymlworkflow with two parallel jobs (FP32 + CMSIS-NN). - Each job exports a model, cross-compiles Pico2 firmware, and checks for expected
.elf/.uf2artifacts plus memory-size constraints.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Use arm-none-eabi-size aggregated totals (text+data for flash, data+bss for SRAM) instead of brittle per-section awk parsing - Increase timeout from 60 to 120 minutes to match other ARM SDK jobs - Add event_name to concurrency group to prevent cross-event cancellation - Add .ci/scripts/** and examples/arm/** to path triggers - CMSIS-NN symbol check now fails the job instead of warning Co-authored-by: Claude <noreply@anthropic.com>
Temporary: allows testing the workflow on this PR. Remove after validation.
There was a problem hiding this comment.
Pull request overview
Adds a new GitHub Actions workflow to continuously validate Raspberry Pi Pico2 firmware builds (FP32 and CMSIS-NN INT8) and enforce memory-size constraints, helping prevent upstream changes from breaking embedded builds.
Changes:
- Introduces
.github/workflows/test-pico2-build.ymlwith two parallel CI jobs for FP32 and CMSIS-NN Pico2 firmware builds. - Each job exports a model, cross-compiles firmware, and validates
.elf/.uf2artifacts plus SRAM/flash usage thresholds. - CMSIS-NN job additionally checks that CMSIS-NN-related symbols are present in the linked binary.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
CMSIS-NN models contain only cortex_m:: ops which are registered by the cortex_m backend, not by portable kernel codegen. Passing these to EXECUTORCH_SELECT_OPS_MODEL produces an empty #include "" in the generated registration code, failing the build. Skip SELECT_OPS_FLAGS when --cmsis is used. Co-authored-by: Claude <noreply@anthropic.com>
- Remove pull_request trigger (testing complete, both jobs passed) - Use head.sha for PR runs to match repo convention Co-authored-by: Claude <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Adds dedicated CI coverage for Raspberry Pi Pico2 firmware builds, ensuring both FP32 and CMSIS-NN INT8 configurations continue to cross-compile and fit within Pico2 memory constraints.
Changes:
- Update Pico2 firmware build script to skip selective build when CMSIS-NN mode is enabled.
- Add a new GitHub Actions workflow that exports models, builds Pico2 firmware (FP32 + CMSIS-NN), and validates produced artifacts and memory usage on push/schedule.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| examples/raspberry_pi/pico2/build_firmware_pico.sh | Skips selective-build flags when building CMSIS-NN firmware to avoid selective-build incompatibilities with cortex_m ops. |
| .github/workflows/test-pico2-build.yml | New CI workflow running two build-and-validate jobs (FP32 + CMSIS-NN) with artifact presence checks and flash/SRAM size validation. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Add set -euo pipefail to both script blocks so pipeline failures in size validation are not masked - Add workflow file itself to push paths so edits trigger CI Co-authored-by: Claude <noreply@anthropic.com>
Adds two parallel CI jobs that validate FP32 and CMSIS-NN INT8 Pico2 firmware builds on every push to main. Each job exports a model, cross- compiles firmware, and validates the .elf/.uf2 artifacts fit within Pico2 memory limits (520KB SRAM, 4MB flash).
Triggered on push to main when examples/raspberry_pi/pico2/** or backends/cortex_m/** files change, plus a daily schedule and release branches