plans vis-a-vis inline functions and templates

Darin Adler darin at apple.com
Tue Dec 16 00:26:48 CET 2003


On Dec 15, 2003, at 12:42 AM, Lars Knoll wrote:

> On Sunday 14 December 2003 18:53, Darin Adler wrote:
>> At Apple, we have a problem with our WebCore framework; it takes a 
>> long time to link, and it's very large (62 MB) when compiled with 
>> debugging symbols and -O0.
>
> Link time is a problem of ld. Michael Matz from SuSE and myself had a 
> look at this in Summer, and managed to get rid of a few places where 
> the linker had quadratic behaviour. Especially for large C++ projects 
> this improved link time dramatically (for Qt link time with debugging 
> symbols went down from approx 3 minutes to about 20 secs on my 
> machine). Most of these changes should be in the CVS version of GNU 
> binutils by now (as it looks one fix for weak symbol merging is still 
> missing, but that should come in soon as well).

I believe that Apple's version of ld, which is not the same as GNU ld, 
does not have this kind of quadratic behavior. Our WebCore framework is 
more than 5x the size of our WebKit framework, but the link time is 
roughly 5x. So for us this is mostly an issue of code size.

> Sounds good. I don't think doing explicit template instantiation is 
> worth the hazzle though.

I hope I can find a better solution, but I don't see one yet.

     -- Darin



More information about the Khtml-devel mailing list