Originally posted by caligula
View Post
Originally posted by pal666
View Post
The reality is that the truth is somewhere between these two statements. There's a lot of things JIT Compilers can do that AoT can't, but at the same time they lack the time to perform aggressive optimization as they have to fight with startup time. At the same time AoT compilers have the time to perform aggressive optimization, but they are limited in just how far they can optimize by having to have Generic Binaries, inability to do PGO and otherwise. The fastest binaries would actually go like this:
Dev Compiles to Device Independent IL -> Application performs aggressive device specific optimization during installation while still leaving enough information in to allow the JITer to act on it -> JITer performs PGO and other runtime optimization while the application is being run.
Additionally the more toolable a language is the higher its optimization potential is because that means that the compiler can know more about the code itself and as a result make better decisions. This is where things like CLang for C++ and Roslyn for C# become especially interesting.
Comment