3 ms·
We’ve been considering this library at work for a performance sensitive application (real time game). Can anyone here speak to the performance and memory usage
by tyleo 3y ago
We’ve been considering this library at work for a performance sensitive application (real time game). Can anyone here speak to the performance and memory usage of QuickJS?
- Ennea 3y agoOut of curiosity, why not Lua?
- chipsrafferty 3y agoWhy Lua?
- szundi 3y agoIs Lua performance sensitive? Other guess is Javascript is much more programmer friendly than Lua.
- nequo 3y agoSome would argue Lua is friendlier than JS. LuaJIT is pretty good as far as performance goes. In these benchmarks, sometimes slower than Node/Bun but uses consistently less memory too: https://programming-language-benchmarks.vercel.app/lua-vs-javascript https://programming-language-benchmarks.vercel.app/lua-vs-ja...
- _vufv 3y agoHere are some benchmarks: https://bellard.org/quickjs/bench.html https://bellard.org/quickjs/bench.html
- rdtsc 3y agoPerformance is pretty good if you consider starting and running small scripts. There is an interesting feature of compiling a js file into a C array bytecode so your runtime code could load that directly skipping the parsing step. For a long running orlarge JS code something like Spidermonkey or V8 with their JITs might be faster. But they are not as embedding friendly and their code bases are much larger.