This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: any "smart linking" efforts?

[Get raw message]
Thanks Eric.
The compiler / linker options suggested by 2) have a generous intent, but
they don't work with dynamic linking :(

Am I asking for an impossible to implement feature?
There seem to be linkers out there (for platforms that should remain
nameless) that are capable of garbage-collecting unused functions even when
the executable is dynamically linked against system libraries.

Also, the same linker can figure out when two functions are bitwise
identical (say two C++ template instantiations in different translation
units) and keep only one copy.

-- Cristi

> -----Original Message-----
> From: Eric Christopher [mailto:echristo@twigboy.cygnus.com]
> Sent: Monday, November 12, 2001 3:24 PM
> To: Cristi Vlasceanu
> Cc: binutils@sources.redhat.com
> Subject: Re: any "smart linking" efforts?
>
>
> > I am thinking mainly of
> > 1) being able to specify libraries in any order and only once
> in the linker
> > command line
>
> like --start-group --end-group?
>
> > 2) having the linker discard symbols that are never being
> referenced (maybe
> > with some help from the assembler?)
> >
>
> gcc -ffunction-sections / ld --gc-sections?
>
> -eric
>
> --
> Fridays are not "pants optional"
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]