On Fri, Mar 25, 2016 at 11:40:11AM -0400, Steven Schveighoffer via Digitalmars-d wrote: > On 3/25/16 11:07 AM, Andrei Alexandrescu wrote: > >On 3/25/16 10:07 AM, Steven Schveighoffer wrote: > >> > >>We should actually be moving *away from* voldemort types: > >> > >>https://forum.dlang.org/post/[email protected] > >> > > > >Has this bug been submitted? -- Andrei > > I'm not sure it's a bug that can be fixed. It's caused by the design > of the way template name mangling is included. > > I can submit a general "enhancement", but I don't know what it would > say? Make template mangling more efficient? :) > > I suppose having a bug report with a demonstration of why we should > change it is a good thing. I'll add that. [...]
We've been talking about compressing template symbols a lot recently, but there's a very simple symbol size reduction that we can do right now: most of the templates in Phobos are eponymous templates, and under the current mangling scheme that means repetition of the template name and the eponymous member in the symbol. My guess is that most of the 4k symbol bloats come from eponymous templates. In theory, a single character (or something in that vicinity) ought to be enough to indicate an eponymous template. That should cut down symbol size significantly (I'm guessing about 30-40% reduction at a minimum, probably more in practice) without requiring a major overhaul of the mangling scheme. T -- Windows: the ultimate triumph of marketing over technology. -- Adrian von Bidder
