Potential of a compiler that creates the executable at once

rempas rempas at tutanota.com
Sat Feb 12 19:31:28 UTC 2022


On Saturday, 12 February 2022 at 16:13:55 UTC, H. S. Teoh wrote:
>
> I use dmd for the code-compile-test cycle because of the fast 
> turnaround. For small programs dmd is so fast it's almost like 
> programming in a scripting language(!). For larger programs 
> it's less so, but still impressively fast for compile times.
>
> Runtime performance of executables compiled by dmd, however, is 
> a disappointment.  I consistently get 20%-40% runtime 
> performance improvement by compiling with ldc/gdc, esp. for 
> CPU-intensive programs.
>
> So my usual workflow is dmd for code-compile-test, ldc -O2 for 
> release builds.
>
>
> T

If you get to a point that runtime becomes too slow for a 
specific task then I don't think that 20%-40% will make such of a 
big difference really. There may be cases that even the smallest 
performance boost will make the difference but were that a lot in 
your experience?

The funny stuff is that I may be stupid and talking about things 
I don't have experience with but I'm just talking with logic in 
mind so If I'm wrong then please make sure to properly fix me and 
tell me your experience on this topic. Thank you!


More information about the Digitalmars-d mailing list