[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Installing luaJIT : no performance gain !
- From: Mike Pall <mikelu-1101@...>
- Date: Tue, 25 Jan 2011 16:16:41 +0100
Sylvain Fabre wrote:
> After a few tests with some scripts, i have strictly no performance
> gain between both versions. Even worse : in some cases, luaJIT is
> slower than lua51.
How much of the CPU time of your application is spent in Lua code?
How much of the CPU time is spent in C/Lua and Lua/C transitions?
If you cannot readily answer these questions then I suggest to
profile your application first.
> I am sure to use the right LUA DLL, as the "jit" object exists when
> i link with luaJIT.
Umm, which version do you use?
> I guess that i forgot something at the installation or run level. Any idea ?
Have you followed the instructions in
> Or do you have a typical bench script, in order for me to be sure
> that i can reproduce the same environnement than in the benchmark
> page of luaJIT ?
Here's a trivial test:
local x=0; for i=1,1e9 do x=math.abs(x) end
This should run in a fraction of a second with LuaJIT 2.0, but
will take more than a minute with Lua. It's around 214x faster.