Ask HN: What is the point of JIT compilation?
The argument goes that the JIT compiler can produce highly optimised code by using run time information of the code hot paths and applying a multitude of optimisations. It is said that is can produce code that can outperform C++.
That sounds great in theory but in reality JIT languages are slower than statically compiled languages. CPU cycles have to be dedicated at run time to analyse and optimise code.
I'm struggling to articulate but in essence my dilemma is the JVM is a marvel of engineering with many many hours spent developing it. However the end result (from a performance metric) is that JIT programs are not faster than statically compiled programs.
So what is the purpose of the JIT compilation model for statically typed languages over AOT compilers?