I have firmware a project that needs to have some .text sections split up into different memory areas.
They are spilt using the names of the source-code files, or by function name wildcards in the linker script file.
When LTO is not enabled, the .text sections are split up correctly. When LTO is enabled, they are not.
I do understand why this is happening, but i'm trying to work out a way around it so i can use LTO.
Is there a workaround for this?
I know i can specify a destination section in the code itself by using __attribute__((section(".xxx")))
, but i would like to avoid this as i would need to do it to a lot of code.
Thanks in advance!