Hi all,
Summary and results of the project “Speculative Compilation in LLVM ORC JIT v2” can be found here : link.

We recommended the user’s of LLVM ORC v2 APIs to use it and the feedback are highly appreciated. We included an example under /LLVM/examples under the name : SpeculativeJIT.cpp. You can use it as a guide to implement your own custom JIT stack. It doesn’t require any additional APIs modifications except calling a new method in CompileOnDemandLayer.

With this proof of concept implementation, we reduce the total wall clock time of Spec 403.gcc from 18.4 seconds (Lazy Compilation) to 10.7 seconds (Speculative Compilation).

Please, try this out and file bugs if any under ORCJIT component in Bugzilla and CC me. If you have any questions and suggestions please let me know!