On Tuesday, 24 July 2012 at 22:19:07 UTC, Jonathan M Davis wrote:
On Tuesday, July 24, 2012 15:49:38 Nick Sabalausky wrote:
Yea. Programs using Goldie ( semitwist.com/goldie ) take a long time to compile (by D standards, not by C++ standards). I tried to benchmark it a while back, and was never really confident in the results I was getting or my understanding of the DMD source, so I never brought it up before. But it *seemed* to be template matching that was the big bottleneck (ie, IIUC, determining which template to instantiate, and I think the function was actually called "match" or something like
that). Goldie does make use of a *lot* of that sort of thing.

I don't have any hard evidence for it, but I've always gotten the impression that it was templates, mixins, and CTFE which really slowed down compilation. Certainly, they increase the memory consumption of the compiler by quite a bit. My guess would be that if we were looking to improve the compiler's performance, that's where we'd need to focus. But we'd have to actually profile the compiler on a variety of projects to be sure of that (which is at least
partially related to what Andrei is suggesting).

- Jonathan M Davis

There's also the nasty O(n^2) optimiser issue.

http://d.puremagic.com/issues/show_bug.cgi?id=7157

Reply via email to