5 ms·
Great stuff! It's interesting to see LLVM taking over the world not only in ahead-of-time compilation, but also in JIT. There are other JIT compiler framework
by MaxBarraclough 9y ago
Great stuff!
It's interesting to see LLVM taking over the world not only in ahead-of-time compilation, but also in JIT.
There are other JIT compiler frameworks out there, like GNU Lightning, but only LLVM seems to have any traction.
- anarazel 9y ago> There are other JIT compiler frameworks out there, like GNU Lightning, but only LLVM seems to have any traction. I looked at a few libraries before deciding on LLVM. Lightning isn't that interesting for postgres' use case for a few reasons. The biggest issue is that it can really be used to implement inlining of operators defined in C - there's no equivalent of LLVM bitcode generated from C that can then be inlined. Secondarily, it doesn't include, afaict, much of an optimizer. That's not great for postgres' usecase. The inlining issue imo makes it really hard to compete with LLVM, even though there's quite some space for a code generator and optimizer much more tuned towards emission speed.