pkarashchenko opened a new issue, #17503:
URL: https://github.com/apache/nuttx/issues/17503

   ### Description
   
   I was trying to build code with GCC and LTO enabled. I observe link time 
warnings
   ```
   lto-wrapper: warning: Extra option to '-Xassembler': -mthumb, dropping all 
'-Xassembler' and '-Wa' options.
   lto-wrapper: warning: using serial compilation of 2 LTRANS jobs
   lto-wrapper: note: see the '-flto' option documentation for more information
   ```
   I see that it is because of `ARCHOPTIMIZATION += -Wa,-mthumb` and 
`ARCHOPTIMIZATION += -Wa,-mimplicit-it=always` that were added by 
https://github.com/apache/nuttx/commit/9ab97df0a57 and 
https://github.com/apache/nuttx/commit/77aede7c87b
   
   The https://github.com/apache/nuttx/commit/9ab97df0a57 has description from 
GCC 4.5.x and in later GCC versions I do not see description that requires 
explicit passing of `-mthumb` with `-Wa` option to assembler.
   
   For https://github.com/apache/nuttx/commit/77aede7c87b I would like to 
reproduce an error if possible locally and check. I see that commit message 
references to ARM Clang, but `-Wa,-mimplicit-it=always` is passed without 
checking for `ifeq ($(CONFIG_ARM_TOOLCHAIN_ARMCLANG),y)`, so I would to better 
understand the issue and a way to fix it.
   
   ### Verification
   
   - [x] I have verified before submitting the report.


-- 
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