Repository navigation
ci(nrf52): disable LTO on xiaoblesense_adafruit to dodge arm-gnu 15.2 LTO bug - #2642
Conversation
… LTO bug Post-#2636 / #2638 post-merge build still fails — but now on a pre-existing toolchain bug, not on the variant.h issue this PR addressed. arm-gnu-toolchain 15.2.rel1 + Adafruit nRF52 BSP + LTO emits thousands of "offset out of range" assembler errors in the LTO-temp output: .lto-tmp/ccXXXXXX.s:13834: Error: offset out of range lto-wrapper: fatal error: arm-none-eabi-gcc returned 1 exit status collect2: error: ld returned 1 exit status Affects xiaoblesense_adafruit, supermini_nrf52840, and likely the other nRF52840 Adafruit-BSP boards. Tracked separately in #2641. CI-unblock: add `build_unflags=[-flto]` + `build_flags=[-fno-lto]` to the xiaoblesense_adafruit board entries so this board's CI goes green now. Other affected boards can adopt the same workaround once verified. Refs #2634 (variant.h), #2636 (variant fix), #2638 (PCA10056 guard), #2641 (LTO toolchain bug). Co-Authored-By: Claude Opus 4.7 <[email protected]>
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughBoth XIAOBLESENSE Adafruit nRF52 board definitions in ChangesLTO Disabling for nRF52 Boards
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related issues
Possibly related PRs
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
#2655) xiaoblesense_adafruit post-merge run 26700835813 succeeded at every compile step (all 65 example builds green — the variant.h / PCA10056 / LTO fixes from #2636 / #2638 / #2642 all worked) but the runner was killed 37 minutes after the last log line during the Optimization Report step (`uv run ci/optimization_report.py --first`). Both Symbol Analysis and Optimization Report are post-build analysis steps already marked `continue-on-error: true`, so they should never turn a green build red. A 5-minute `timeout-minutes` cap keeps them from hanging the entire job when a downstream script (e.g. fbuild vs PIO artifact-path divergence — readelf/nm/objdump returned exit 1 on the firmware.elf earlier in the same run) gets stuck in a wait loop. The build itself still passes; the report is just skipped for that run. Filed the underlying optimization_report.py / symbol_analysis_runner.py fbuild-path bug separately for proper investigation. Refs #2641. Co-authored-by: Claude Opus 4.7 <[email protected]>
… bug) (#2654) The arm-gnu-toolchain 15.2.rel1 + Adafruit nRF52 BSP combination produces "offset out of range" assembler errors in the LTO temp file during link, the same bug that hit xiaoblesense_adafruit (#2641 / PR #2642). The non-Seeed nRF52840 boards have now crossed the same threshold: .lto-tmp/ccEo9QPb.s:13834: Error: offset out of range ... build error: build failed: arm-none-eabi-gcc link failed lto-wrapper: fatal error: arm-none-eabi-gcc returned 1 exit status Apply the same `-fno-lto` workaround to: - NRF52840 (board_name="nrf52840_dk") - ADA_FEATHER_NRF52840_SENSE (board_name="adafruit_feather_nrf52840_sense") - SUPERMINI_NRF52840 (board_name="supermini_nrf52840") NICE_NANO_NRF52840 and NRFMICRO_NRF52840 use the same toolchain but are currently passing — leave them alone (don't pre-emptively disable LTO on passing builds; size regressions). Re-apply only when/if they fail. Fixes #2653
Summary
CI-unblock for xiaoblesense_adafruit. After #2636 (variant.h) and #2638 (PCA10056 guard) shipped, the post-merge build still failed — but on a different, pre-existing toolchain bug: arm-gnu 15.2.rel1 + Adafruit nRF52 BSP + LTO emits thousands of "offset out of range" assembler errors in LTO-temp output (see run 26700353292).
This bug affects
supermini_nrf52840and presumably the other nRF52840 Adafruit-BSP boards too. Filed as #2641 for the proper toolchain investigation.Workaround: add
build_unflags=["-flto"]+build_flags=["-fno-lto"]toXIAOBLESENSE_ADAFRUIT_NRF52and the typo-alias entry inci/boards.py. CI goes green now; #2641 tracks the toolchain root cause and broader rollout of the workaround.Refs #2634, #2636, #2638. Partial #2641.
Test plan
build_xiaoblesense_adafruitjob on master is green post-mergeadafruit_xiaoblesenseworkflow on master is green post-merge🤖 Generated with Claude Code
Summary by CodeRabbit