lkml.org 
[lkml]   [2022]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [RFC PATCH] kbuild: pass objects instead of archives to linker
From
On 02. 11. 22, 10:44, Masahiro Yamada wrote:
> Jiri Slaby reported that the (not-upstreamed) GCC-LTO tree got broken
> due to 321648455061 ("kbuild: use obj-y instead extra-y for objects
> placed at the head")
>
> https://lore.kernel.org/linux-kbuild/ea468b86-abb7-bb2b-1e0a-4c8959d23f1c@kernel.org/
>
>
> I am not pretty sure because I did not check the downstream code.
>
>
> If I understood his report correctly, the reason for the breakage is
> because I put all objects into the thin archive, expecting
> the linker would preserve the object order in the archive.
>
> By specifying the object order directly in the command line,
> GCC-LTO should get back working again.

...

> I think my patch is unneeded (hence RFC), but I just wanted to know
> if linkers (gnu ld and lld) see any difference.

Yes, including your patch (instead of vmlinux.S and /compressed/*
changes) also fixes the issue. So the linker (gcc-ld) indeed respects
command line, but not order of objects in .a.

thanks,
--
js
suse labs

\
 
 \ /
  Last update: 2022-11-03 08:23    [W:0.050 / U:0.520 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site