dmd makes D appear slow

weaselcat via Digitalmars-d digitalmars-d at puremagic.com
Fri May 29 13:56:59 PDT 2015


On Friday, 29 May 2015 at 20:02:49 UTC, Martin Krejcirik wrote:
> Note to benchmark users: please use ldc compiler with -inline 
> -O -boundscheck=off (or whatever is correct for LDC) options 
> for best results

AFAIK you shouldn't use the -inline flag with LDC, as it tells 
LDC to run the inline LLVM pass. LDC's inlining is enabled with 
-enable-inlining and is enabled at -O2 and higher. I believe 
these are similar except LDC's -enable-inlining has better cost 
analysis configured for the pass(?)

-inline should probably be renamed because this is confusing due 
to dmd's usage of it.

But yes, a simple blurb on which compiler flags to use for 
optimization would probably help as there seems to be some 
confusion about this due to differing compiler flags. I imagine 
Iain, Kai, Nadlinger, etc would know which ones to use.


More information about the Digitalmars-d mailing list