The symbols are now marked as jh@gcc10:~/trunk/build4/gcc$ nm t.o 0000000000000001 C __gnu_lto_v1 0000000000000001 C __gnu_slim_lto When those symbols are present, it would be very useful if nm/ar/ld output warning explaning that plugin needs to be used. Honza
See 14698.
> Bug 14698 Summary: ar, nm and ranlib don't use gcc's liblto_plugin.so in BINDIR/../lib/bfd-plugins automatically > https://sourceware.org/bugzilla/show_bug.cgi?id=14698 Will we now get some sort of warning/error when the LTO objects are used but plugin is not found in the search path? Honza
On Thu, 3 Apr 2014, hubicka at ucw dot cz wrote: > https://sourceware.org/bugzilla/show_bug.cgi?id=13227 > > --- Comment #2 from hubicka at ucw dot cz --- > > Bug 14698 Summary: ar, nm and ranlib don't use gcc's liblto_plugin.so in BINDIR/../lib/bfd-plugins automatically > > https://sourceware.org/bugzilla/show_bug.cgi?id=14698 > > Will we now get some sort of warning/error when the LTO objects are used but > plugin is not found in > the search path? No, bfd relies on the plugin to detect LTO objects thus if there is no plugin then it won't know it's an LTO object
*** Bug 15300 has been marked as a duplicate of this bug. ***
So is it sufficient (and safe) to warn just on the presence of __gnu_slim_lto?
(In reply to Alan Modra from comment #5) > So is it sufficient (and safe) to warn just on the presence of > __gnu_slim_lto? Yes, I think so.
> So is it sufficient (and safe) to warn just on the presence of __gnu_slim_lto? Yes, when __gnu_slim_lto gets into linking/archiving/nm, I think it is safe to warn about missing plugin. Honza
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "gdb and binutils". The branch, master has been updated via b794fc1d1c3a3dfb65b74a36fe96c474fee65000 (commit) from 774bb79e9b9e192bcecc38da919edffaf9b5d236 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=b794fc1d1c3a3dfb65b74a36fe96c474fee65000 commit b794fc1d1c3a3dfb65b74a36fe96c474fee65000 Author: Alan Modra <amodra@gmail.com> Date: Mon Jul 28 22:18:25 2014 +0930 Warn for ar/nm/ranlib/ld on lto objects without plugin PR 13227 bfd/ * archive.c (_bfd_compute_and_write_armap): Warn on adding __gnu_lto_slim to armap. * linker.c (_bfd_generic_link_add_one_symbol): Warn on adding __gnu_lto_slim to linker hash table. binutils/ * nm.c (filter_symbols): Warn on __gnu_lto_slim. ----------------------------------------------------------------------- Summary of changes: bfd/ChangeLog | 8 ++++++++ bfd/archive.c | 4 ++++ bfd/linker.c | 8 +++++++- binutils/ChangeLog | 5 +++++ binutils/nm.c | 4 ++++ 5 files changed, 28 insertions(+), 1 deletions(-)
Fixed
> Fixed Thanks, does this also cover gold linker? Honza
No, I didn't do anything about gold.
Created attachment 7730 [details] gold patch This should fix gold
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "gdb and binutils". The branch, master has been updated via 7cd4e5b756fa5c1ebe0ba7dd04e45d46330a7675 (commit) from 8e07a239c12ba3b746ef0cf2c53d572315aef654 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=7cd4e5b756fa5c1ebe0ba7dd04e45d46330a7675 commit 7cd4e5b756fa5c1ebe0ba7dd04e45d46330a7675 Author: Alan Modra <amodra@gmail.com> Date: Wed Aug 6 12:40:00 2014 +0930 Warn for gold on lto objects without plugin PR 13227 * symtab.cc (Symbol_table::add_from_relobj): Warn on __gnu_lto_slim. ----------------------------------------------------------------------- Summary of changes: gold/ChangeLog | 5 +++++ gold/symtab.cc | 4 ++++ 2 files changed, 9 insertions(+), 0 deletions(-)