I just saw this post on hackernews, where an LLVM compiler backend (github) was posted that claims to get 10-20x compile time speedup compared to an LLVM 19 baseline.
Quoting from the linked LLVM-Discourse thread:
How to use TPDE-LLVM?
The LLVM back-end is usable as a library (e.g., for JIT compilation, also usable with ORC JIT), as
llc
-like tool, and can be integrated in Clang (needs a patch, plugins can’t provide a custom back-end right now). Some more details here.
So I am wondering if it would be possible to compile Julia with this LLVM backend, at least for use-cases for which O0 or O1 type performance is acceptable.
I don’t know too much about how exactly LLVM is currently called from Julia, but quoting the TPDE-LLVM docs:
Library usage is possible through tpde_llvm::LLVMCompiler, which supports compiling a module to an object file or mapping it into the memory of the current process for JIT execution. The JIT mapper only supports very typical ELF constructs (e.g., no TLS), if this is not sufficient, the object file can also be mapped through LLVM’s ORC JIT (see tpde-llvm/tools/tpde-lli.cpp for an example).
Perhaps someone can comment on the feasibilty here.