3 ms·
LuaJIT is such an amazing just-in-time compiler, faster than the traditional Lua compiler, supported on many platforms and used everywhere where speed and perfo
by fosk 11y ago
LuaJIT is such an amazing just-in-time compiler, faster than the traditional Lua compiler, supported on many platforms and used everywhere where speed and performance are a priority.
For example it's being used in Redis to provide Lua scripting, and can also be used with nginx (OpenResty). While developing Kong (https://github.com/Mashape/kong https://github.com/Mashape/kong) we noticed that LuaJIT provided substantial performance improvements.
I hope that the recent step down of the main committer won't affect the future of the project [1].
[1] http://www.freelists.org/post/luajit/Looking-for-new-LuaJIT-maintainers http://www.freelists.org/post/luajit/Looking-for-new-LuaJIT-...
- samatman 11y agoMike Pall is more than just the main committer: he's the designer, practically speaking the author. He's done a lot to advance the state of the art in tracing compiling. It's fascinating to compare LuaJIT's implementation to the huge complexity and resulting lengthy compile times of the JIT compiler built into LLVM. Mike learned a lot from Smalltalk, IIRC. I'm kinda sad that this means we probably won't get to see his four-color garbage collector[0]. That's a great link, taught me a lot about garbage collection in general. [0] http://wiki.luajit.org/New-Garbage-Collector http://wiki.luajit.org/New-Garbage-Collector That all said, CloudFlare is good hands to put the project in, and I foresee good things in store for it.
- asymmetric 11y agoKong looks like a really interesting project! Just curious as to why you chose Lua, and what your experience with it was.
- fosk 11y agoWe decided to use Lua because we are leveraging OpenResty [1]. It took a while to setup the development environment, since there aren't many big, public, projects based on OpenResty + Lua, but we are on a good track now. Lua is a very simple language, no batteries included, that's easy to learn and actually quite fun to write. It also has a package manager called Luarocks [2] (that Kong is sponsoring too). The ecosystem is still relatively young, but it's growing - and that's also thanks to tools like LuaJIT. [1] http://openresty.org/ http://openresty.org/ [2] https://luarocks.org/ https://luarocks.org/
- lttlrck 11y agoLuaJIT is used by a fork of Redis [0]. The official antirez/Redis uses PUC Lua. [0] https://github.com/neomantra/redis/tree/luajit https://github.com/neomantra/redis/tree/luajit