3 ms·
This should be a fairly unsurprising result. High level languages are fundamentally more optimisable than low level ones because, as you say, the latter expres
by moonchild 3y ago
This should be a fairly unsurprising result. High level languages are fundamentally more optimisable than low level ones because, as you say, the latter express unnecessary constraints, lacking information about domain-level semantics. Low-level optimisations are also known to follow a pareto distribution wrt their efficacy: 20% of the optimisations are responsible for 80% of your performance (if not more). See for example mir - https://developers.redhat.com/blog/2020/01/20/mir-a-lightweight-jit-compiler-project https://developers.redhat.com/blog/2020/01/20/mir-a-lightwei...
That said:
> It seems to me that the LLVM optimisations are only of benefit to you if you generate really bad LLVM code in the first place.
Much llvm development is sponsored by large corporations for whom it really is worth it to squeeze that last 1%.