Subject: Re: New ld.elf_so from FreeBSD
To: Charles Hannum <>
From: Jason R Thorpe <>
List: tech-toolchain
Date: 09/05/2002 12:44:17
On Thu, Sep 05, 2002 at 02:24:36AM +0000, Charles Hannum wrote:

 > * C++ code (and thus GNOME, KDE, mozilla, etc.) starts up much faster.

junyoung has a patch that addresses this problem.

 > * The Alpha platform attains reasonable performance, where right now
 >   things like the XF86 4 server are basically unusable.

What you've neglected to tell the list is that you have already patched
our ld.elf_so to fix this problem, but have not yet checked it in to the

 > * The occasional `undefined PLT symbol' problems (on Alpha) are gone.

Again, you neglected to tell the list that you debugged, and fixed, this
already in our ld.elf_so.

 > * Multi-threading support (i.e. r/w locking for dl*() calls) is added.

I think there are some problems with this.

	1. We've been talking a lot about performance of the dynamic
	   linker lately.  The r/w locking is totally unnecessary for
	   non-threaded applications.  Making non-threaded applications
	   pay the penalty of using them seems to go against the spirit
	   of improving performance.

	2. Since not all platforms have the required atomic primitives
	   to support the r/w locking, the expense incurred by using them
	   for non-threaded apps might, in fact, be substantial (e.g.
	   unnecessarily making all processes on that platform use RAS,
	   for example).

I agree that we need r/w locking support in our rtld, but I think the
problem is big enough that we need to think about it a while longer before
simply adopting a solution from some other system which doens't run on
as many platforms as we run on.

        -- Jason R. Thorpe <>