[Bug lto/83967] LTO removes C functions declared as weak in assembler(depending on files order in linking)
rguenther at suse dot de
gcc-bugzilla@gcc.gnu.org
Tue Jan 23 09:12:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83967
--- Comment #10 from rguenther at suse dot de <rguenther at suse dot de> ---
On Tue, 23 Jan 2018, hurwic8 at gmail dot com wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83967
>
> --- Comment #7 from Rafał Mszal <hurwic8 at gmail dot com> ---
> Thanks for response.
>
> I've send some basic example of the failure. However, it needs some others file
> to compile and link, like linker, SystemInit function decalration and so on.
>
> I've just send you most important files, now I am working on removing sources
> that are not important, but this will take me a while, since i need to remove
> lot of dependencies between those files, makefile and linker.
>
> I've checked 'used' attribute, it doesn't solve the problem. Same with the
> suggested '-fuse-linker-plugin' flag.
From my analysis the issue is with GNU ld and you could avoid hitting
it by using gold (you can say -fuse-ld=gold to GCC if you have gold
installed)
More information about the Gcc-bugs
mailing list