lua-users home
lua-l archive

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


Hi,

Related to my post about why I have not used the JIT technology in
Ravi for my project (yet), is the question: do we need a JIT for Lua
at all?

I have no data points to tell me under what conditions a JIT makes
sense, apart from artificial benchmarks. The most obvious use case is
games programming I guess where the highest performance is needed, but
I am not a games programmer and do not know whether interpreted Lua is
good enough in this case.

In my opinion, having worked on Ravi and in my usage of it, Lua is not
a general purpose language that you would use to build a large scale
application. This is not because of any deficiency in Lua, it is more
that large scale development is better done in statically typed
languages like Java, C#, Go, Swift etc. The cost of developing complex
applications in a dynamic language is just too high. I know that many
folks on this list will probably disagree with this view, but leaving
aside your love for Lua and your wish to use Lua everywhere, would you
still use Lua as a general purpose application development platform?

I find that Lua is best suited in the context it was designed for - as
a light weight embedded scripting language that allows a system to
provide extensibility. Or as a scripting language for small standalone
tasks. And in these scenarios JIT technology is not always needed I
feel.

I feel that some folks use LuaJIT more as a substitute for C - i.e.
they would have coded in C but that is too hard to do, whereas LuaJIt
gives you almost similar capabilities in a much easier to use package,
so they use LuaJIT as if it is C. What do you guys think?

Apologies if this post is a more about philosophical questions related
to using Lua. I am just sharing some thoughts I have had for a while.

Regards
Dibyendu