public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* RFC [PATCH 0/2] Use ld_plugin_symbol_type and ld_plugin_symbol_section_flags
@ 2020-03-18 12:06 H.J. Lu
  2020-03-18 12:06 ` RFC [PATCH 1/2] Update include/plugin-api.h H.J. Lu
  2020-03-18 12:06 ` RFC [PATCH 2/2] Use ld_plugin_symbol_type and ld_plugin_symbol_section_flags H.J. Lu
  0 siblings, 2 replies; 5+ messages in thread
From: H.J. Lu @ 2020-03-18 12:06 UTC (permalink / raw)
  To: binutils

Since LTO plugin may generate more than one ltrans.o file from one input
IR object as LTO wrapper ignores -flto-partition=none:

lto-wrapper.c:608:

   604          /* Drop arguments that we want to take from the link line.  */
   605          case OPT_flto_:
   606          case OPT_flto:
   607          case OPT_flto_partition_:
   608            continue;

the LTO wrapper approach is not only slow but also unreliable.  There is
a proposal to extend The LTO plugin API to add LDPT_ADD_SYMBOLS_V2 with
symbol type and section flags:

https://gcc.gnu.org/pipermail/gcc-patches/2020-March/542187.html

We can use the new LTO plugin API to get symbol type, instead of invoking
the LTO wrapper.

H.J. Lu (1):
  Use ld_plugin_symbol_type and ld_plugin_symbol_section_flags

Martin Liska (1):
  Update include/plugin-api.h

 bfd/plugin.c         | 66 ++++++++++++++++++++++++++++++++++----------
 include/plugin-api.h | 32 +++++++++++++++++++--
 2 files changed, 82 insertions(+), 16 deletions(-)

-- 
2.25.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-03-20  2:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-18 12:06 RFC [PATCH 0/2] Use ld_plugin_symbol_type and ld_plugin_symbol_section_flags H.J. Lu
2020-03-18 12:06 ` RFC [PATCH 1/2] Update include/plugin-api.h H.J. Lu
2020-03-19 16:09   ` [PATCH] " H.J. Lu
2020-03-20  2:33     ` Alan Modra
2020-03-18 12:06 ` RFC [PATCH 2/2] Use ld_plugin_symbol_type and ld_plugin_symbol_section_flags H.J. Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).