3 ms·
Heh, I missed that there's a new query engine. From [0] it looks like it was available from 5.1, also interesting is that you can't choose which engine to use,
by nevi-me 3y ago
Heh, I missed that there's a new query engine.
From [0] it looks like it was available from 5.1, also interesting is that you can't choose which engine to use, so I suppose it only works on subsets or queries that meet certain conditions.
This isn't the first time I hear something to the effect of "LLVM JIT is great, but it introduces a lot of query latency". I wonder if there are other JIT engines more suitable for compiling potentially small/simple queries.
[0] https://www.mongodb.com/docs/v7.0/reference/sbe/#std-label-sbe-landing https://www.mongodb.com/docs/v7.0/reference/sbe/#std-label-s...
- __s 3y agore LLVM: Yes, Cranelift was designed to address these issues https://github.com/bytecodealliance/wasmtime/blob/main/cranelift/docs/compare-llvm.md https://github.com/bytecodealliance/wasmtime/blob/main/crane... https://blog.benj.me/2021/02/17/cranelift-codegen-primer https://blog.benj.me/2021/02/17/cranelift-codegen-primer https://jason-williams.co.uk/posts/a-possible-new-backend-for-rust https://jason-williams.co.uk/posts/a-possible-new-backend-fo... https://news.ycombinator.com/item?id=25130528 https://news.ycombinator.com/item?id=25130528 30% faster rust build time
- jandrewrogers 3y agoLLVM has many advantages for JIT but it does not prioritize very low latency, choosing to optimize other properties instead. Consequently, LLVM tends to be more popular for systems targeted at analytical workloads where queries commonly have intrinsically high overhead latency. The latency isn't terrible but it is noticeable if you are running a low-latency "fast-twitch" workload. There are other specialized JIT compilers that are essentially purpose-built to provide very low latency; for systems like MongoDB which are rarely used for serious analytical processing, you'd probably want to use one of these instead.