Problems with dmd inlining

Craig Black craigblack2 at cox.net
Sat Dec 11 20:22:34 PST 2010


I did some benchmarking with a simple quick sort algorithm and was very 
disappointed that dmd was over twice as slow as Visual C++.  Investigation 
revealed most of the slowness was due to the fact that dmd was not inlining 
a simple function that returned a reference.  After hand-inlining some code, 
I got within 20% of the performance of Visual C++.  I don't see this as 
acceptable.  The main reason that I want to use D is so that my code will be 
cleaner.  If I have to inline my own functions then this will not result in 
clean code.

Anyway, has anyone else had problems with dmd's inliner?  Should I post a 
bug report or has someone else already complained about this?

-Craig 



More information about the Digitalmars-d mailing list