[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Follow-on from does Lua need a JIT - making Lua's interpreter faster
- From: Sergey Rozhenko <sergroj@...>
- Date: Thu, 23 Feb 2017 19:59:36 +0700
On Ср 22.02.17 22:13, Dibyendu Majumdar wrote:
It seems from the majority of responses so far that JIT is not
essential for Lua, or putting it another way, a majority of use cases
can be satisfied without a JIT.
A natural follow on question is can the interpreter be made faster
without resorting to hand-written assembly code or other esoteric
Big Yes. When I switched from plain Lua to LuaJIT I was very happy with
the speedup. I didn't run the numbers, but it felt like 10x increase in
speed. Then I found out that mobdebug.lua was disabling JIT, so all this
speedup was from faster interpreter. Speedup from enabling JIT wasn't
nearly as big.
This speedup probably comes from faster table access, but I don't know
how LuaJIT achieves it.
What I also love about LuaJIT is that it's the golden standard of Lua in
terms of language design. Lua 5.3 has suffered a huge degradation in
that area due to its combined int64/double type.
Sergey "GrayFace" Rozhenko, mailto:email@example.com