dmd codegen improvements

Walter Bright via Digitalmars-d digitalmars-d at puremagic.com
Tue Aug 18 14:43:43 PDT 2015


On 8/18/2015 1:33 PM, Jacob Carlborg wrote:
> There's profile guided optimization, which LLVM supports.

dmd does have that to some extent. If you run with -profile, the profiler will 
emit a trace.def file. This is a script which can be fed to the linker which 
controls the layout of functions in the executable. The layout is organized so 
that strongly connected functions reside in the same page, minimizing swapping 
and maximizing cache hits.

Unfortunately, nobody makes use of it, which makes me reluctant to expend 
further effort on PGO.

   http://www.digitalmars.com/ctg/trace.html

I wonder how many people actually use the llvm profile guided optimizations. I 
suspect very, very few.



More information about the Digitalmars-d mailing list