public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* discarding rules for duplicate ELF comdat groups
@ 2011-02-01  9:14 Jan Beulich
  0 siblings, 0 replies; 9+ messages in thread
From: Jan Beulich @ 2011-02-01  9:14 UTC (permalink / raw)
  To: generic-abi; +Cc: binutils

I had originally brought this up on the binutils mailing list, but it
was suggested to bring this up in this more generic forum:

It seems like currently the rule simply is to pick the first instance the
linker gets to see. Wouldn't it make sense to honor the group
signature's attributes (namely its binding), and prefer keeping an
instance with a global group signature over a weak or local one?
That would allow the programmer some control over which
instance to keep: My main motivation is to find a way to discard
the various weak fallback functions Linux has to cover cases where
e.g. some architectures implement certain functionality, while
others that don't can all use a generic implementation.

I cannot see other mechanisms that would allow ld to discard
sections (not to speak of individual functions within sections).

Thanks, Jan

^ permalink raw reply	[flat|nested] 9+ messages in thread
* discarding rules for duplicate ELF comdat groups
@ 2011-01-28 13:51 Jan Beulich
  2011-01-28 14:07 ` H.J. Lu
  0 siblings, 1 reply; 9+ messages in thread
From: Jan Beulich @ 2011-01-28 13:51 UTC (permalink / raw)
  To: binutils

It seems like currently the rule simply is to pick the first instance the
linker gets to see. Wouldn't it make sense to honor the group
signature's attributed (namely its binding), and prefer keeping an
instance with a global group signature over a weak or local one?
That would allow the programmer some control over which
instance to keep: My main motivation is to find a way to discard
the various weak fallback functions Linux has to cover cases where
e.g. some architectures implement certain functionality, while
others that don't can all use a generic implementation.

I cannot see other mechanisms that would allow ld to discard
sections (not to speak of individual functions within sections).

Thanks, Jan

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

end of thread, other threads:[~2011-02-01  9:14 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-01  9:14 discarding rules for duplicate ELF comdat groups Jan Beulich
  -- strict thread matches above, loose matches on Subject: below --
2011-01-28 13:51 Jan Beulich
2011-01-28 14:07 ` H.J. Lu
2011-01-28 14:30   ` Jan Beulich
2011-01-28 14:40     ` H.J. Lu
2011-01-28 15:28       ` Jan Beulich
2011-01-28 15:56         ` H.J. Lu
     [not found]           ` <4D4305B6020000780002F372@vpn.id2.novell.com>
     [not found]             ` <AANLkTi=0RD6pYbPjXYJ3tk429WAtBa555GP1ksBedLO9@mail.gmail.com>
2011-01-31  8:02               ` Jan Beulich
2011-01-31 18:19                 ` Ian Lance Taylor

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).