2020-11-02 01:08 PM
Unfortunately there is a bug regarding the LTO option since GCC 7 until at least GCC 9: https://bugs.launchpad.net/gcc-arm-embedded/+bug/1747966
Can you please consider applying the workaround described there?
I.e. in the generated Makefile the startup code has to be passed first to the linker.
Currently the only option is to remove the interrupts from the startup code, as described here: https://www.disk91.com/2020/technology/programming/code-optimization-with-stm32-cube-ide/