dcollections 1.0 and 2.0a beta released

Walter Bright newshound1 at digitalmars.com
Fri May 21 12:40:09 PDT 2010


Andrei Alexandrescu wrote:
>>> See the -mergefunc compiler switch of LDC, to merge identical
>>> functions (like ones produced by template instantiations). This
>>> feature is not very powerful yet, but it's present and I have seen it
>>> works.
>>
>> Indeed. I'm no expert in linkers, but in my opinion this is one of the
>> most basic optimizations a linker should perform. And C++ has pushed
>> linkers to do that for years now so I'd expect most linkers to do that
>> already...
>>
>> The problem with templates are more the multiple slightly different
>> instanciations. In general this is good for performance, but it's only
>> needed for the code paths that need to be fast. I think generic
>> containers should be fast.
> 
> There's been talk that Walter's slow porting of the linker to C and then 
> D will put him in the position to introduce such an optimization.

Unfortunately, it's an agonizingly slow process. It also does nothing for Linux 
or OSX.


More information about the Digitalmars-d-announce mailing list