[PATCH v2] MIPS: Don't move __gnu_lto_slim to .scommon
Maciej W. Rozycki
macro@orcam.me.uk
Thu Jul 20 09:34:43 GMT 2023
On Thu, 20 Jul 2023, Alan Modra wrote:
> I think the patch is OK, but the same should be applied to another
> place to stop objcopy modifying __gnu_lto_slim.
>
> mips-linux-gnu testcase after running make check:
> binutils/objcopy ld/tmpdir/pr15323a-r.o ld/tmpdir/xxx
> then inspect ld/tmpdir/xxx with readelf.
>
> I'm going to apply the following to mainline, and will also apply to
> the 2.41 branch tomorrow if no one objects.
You are the author of this code, so I guess you know what's going on
here. I still don't understand the circumstances that cause linker.c to
reject this symbol if it's in an SHN_MIPS_SCOMMON rather than SHN_COMMON
section, and the relevant git change descriptions (going back to commit
b794fc1d1c3a ("Warn for ar/nm/ranlib/ld on lto objects without plugin"))
do not explain it, so I'd appreciate if you got me enlightened.
Maciej
More information about the Binutils
mailing list