xiaoxiang781216 opened a new pull request, #21928:
URL: https://github.com/apache/nuttx/pull/21928

   ## Summary
   
   Use small defaults for `nucleo-g431rb:nsh` to keep the image within its
   128 KiB flash region. Keep pthread support and FILE streams enabled for
   OSTEST. This addresses the flash overflow seen in #21834 without
   depending on that PR.
   
   ## Impact
   
   BREAKING CHANGE: This configuration enables `DEFAULT_SMALL`, disabling
   optional POSIX APIs, many NSH commands and some OSTEST cases. It is not
   a size-only compiler optimization. Remove `CONFIG_DEFAULT_SMALL=y` and
   regenerate the configuration to restore the previous defaults, subject
   to the flash capacity limit.
   
   Only this board configuration changes. LTO, pthread support, FILE streams
   and OSTEST remain enabled. No API, driver, build-system or documentation
   changes are introduced.
   
   ## Testing
   
   CMake/Ninja with GNU Arm 13.2.1, `nucleo-g431rb:nsh`, using
   `tools/testbuild.sh` and apps revision `41840d466`.
   
   The #21834 CI merge revision `418937215cf` reproduces the overflow:
   
   ```text
   /usr/lib/gcc/arm-none-eabi/13.2.1/../../../arm-none-eabi/bin/ld: nuttx 
section `.text' will not fit in region `flash'
   /usr/lib/gcc/arm-none-eabi/13.2.1/../../../arm-none-eabi/bin/ld: region 
`flash' overflowed by 1256 bytes
   Memory region         Used Size  Region Size  %age Used
              flash:      132328 B       128 KB    100.96%
               sram:       10032 B        22 KB     44.53%
   ```
   
   With the small configuration, that revision builds successfully. The
   candidate also builds on Apache master `1aedf8607f8`. Binary sizes from
   `wc -c nuttx.bin`, respectively:
   
   ```text
   77336 nuttx.bin
   75872 nuttx.bin
   ```
   
   The build runner refreshed the defconfig. These builds exercise the
   link-capacity regression; no runtime unit test is added for changing
   configuration defaults. No hardware/runtime tests, other board
   configurations, protected/kernel builds or Make builds were run for this
   candidate.
   
   ## PR verification Self-Check
   
   - [x] This PR introduces only one functional change.
   - [x] I have updated all required description fields above.
   - [ ] My PR adheres to the Contributing Guidelines and Documentation.
   - [x] My PR is still work in progress (not ready for review).
   - [ ] My PR is ready for review and can be safely merged into a codebase.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to