lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Mike Pall wrote:
LuaJIT is a Just-In-Time (JIT) Compiler for Lua 5.1.
LuaJIT is light-weight, efficient and extensible.

It's a great piece of work (and a really interesting
architecture, small footprint, nice docs).  In some narrow
cases it even makes Lua rather competitive versus optimized
GCC code.

LuaJIT's maths speed is excellent and probably where it
comes closest to C's performance.  Loops are good too.
Table access is a lot slower than C array access, but to
some extent that's the price to be paid for safe and dynamic
arrays, though it's a shame since of course many interesting
applications of Lua will naturally use table access with
abandon.  I haven't compared string handling or call speed.

I'm comparing LuaJIT to C because for me, LuaJIT is a lot
more interesting for its ability to displace future C code
than for its ability to run existing Lua code faster.  I
think that LuaJIT (this version in particular) starts to
open Lua up to some domains in which Lua was not performant
enough previously.