Jason House wrote:
Walter Bright Wrote:

Jason House wrote:
I wish I had your problems. I ported a sizable set of C++ code to D2 and discovered D2 with dmd was 50x slower than C++ with gcc! I've been to busy/disappointed to track down the bug(s) causing such a slowdown. If
anyone is sufficiently inspired to find the bugs, I can make the GPL
source code available.

50 times slower is not likely to be a problem with inlining, it's likely to
be an algorithmic one.

Normally, yes, I'd agree. But in this case, it's merely a port of the C++
source code, so all algorithms are identical. The only change I did initially
was to use ranges, but even after replacing those with mixins, the
performance was equally as bad. There's also no memory allocations, so the GC
isn't an issue either. There are also benchmarks on behavior that make me
fairly confident the behavior is comparable.

There's something funky going on. Inlining can't explain anywhere near a 50x 
change.

Reply via email to