Am Fri, 15 Apr 2016 09:04:21 +0000
schrieb Johan Engelen <j...@j.nl>:
> On Wednesday, 13 April 2016 at 11:34:26 UTC, Johan Engelen wrote:
> > Hi all,
> > I've written an article about how I implemented
> > profile-guided optimization (PGO) of virtual calls to direct
> > calls (a micro-micro-optimization, expected performance gain of
> > just a few percent if any!).
> I've updated the article with performance measurements of just
> the D code of LDC: the improvement with PGO is about 7% !
Compilers are full of logic that makes some code 0.5% faster.
The sum of all these little bits is what makes up an
optimizing compiler and if today you still find an optimization
that's worth 1 or 2% you have a jackpot!
7% is quite a bit more than any other option like -cpu=native
could achieve. If feasible I'd enjoy if ldc2 shipped with a
pgo configuration option. If you use the compiler in a lot of
edit/compile cycles it will pay off.