On Jan 13, 10 10:57, Adam D. Ruppe wrote:
On Tue, Jan 12, 2010 at 10:09:01PM -0300, Leandro Lucarella wrote:
In Linux, using a distribution, you have a pretty good change that dynamic
libraries are used by more than one program.
That's actually not true. I ran a program on my system a long time ago that
ran ldd against everything in /bin, /lib, and all the various variants.
http://arsdnet.net/lib-data-sorted.txt
Notice that the *vast* majority of those libraries are used by only a
handful of binaries on the system. Half has five or fewer users.
The data is flawed. For example, libtiff appears as
/usr/lib/./libtiff.so.3 (2 uses) and /usr/lib/libtiff.so.3 (70 uses).
Moreover, as long as there are ≥2 uses it's disk usage is already lower
than static linking.
This is slightly biased by not counting dynamically loaded things; ldd
only does statically requested shared libs. But I doubt that changes things
significantly.
Also note how at the bottom of the list, users go up quickly - the basic
system libraries are used by a great many apps. Most everything else is
pretty specialized though.
I don't remember where I put the source to the program that generated that
list, but it isn't too hard to recreate; it just counts references that
ldd outputs.
typeinfo/template bloat too to analyze in the executables bloat
I'm sure the linker will eventually take care of templates.
As to typeinfo, does D need it anymore? It seems like templates obsolete
most the typeinfo now.