Get the latest tech news
Bringing the Instructions to the Data
To The Data Why? What? Since leaving Old Job I've been missing interesting database work. One paper that has been in the back of my mind is for a few years is Efficiently Compiling Efficient Query Plans for Modern Hardware1 which details how Tableau's internal engine, HyPer, compiles SQL statements into LLVM IR.
I have zero LLVM IR experience but I found it pretty straightforward to write after a bit of practice and find it similar to functional programming. It will usually be a bit more verbose, but I find that writing this in Rust lends a large amount of confidence compared to hand written experiments. Additionally for these examples, we are relying on a similar struct found in the Inkwell's README to maintain the CodeGen state and the same mechanism to execute the compiled IR.
Or read this on Hacker News