I compiled LÖVE 0.7.2 for Mac and Windows using the latest (2.0.0-beta7) LuaJIT build. I don't have access to a Linux distro so I didn't make a Linux version.
Downloads
Intel-based Macs
Windows
There is no PowerPC version of LuaJIT for OS X, unfortunately. The windows version needs the new "Lua51.dll" file because LuaJIT for Windows needed to be compiled dynamically rather than statically.
Here's a couple example screenshots of LÖVE using this implementation of simplex noise for Lua (it utilizes LuaJIT's FFI):
It takes about 0.13 seconds for me to map a 512x512 pixel imagedata using simplex2d values and LuaJIT.
LoveJIT
Re: LoveJIT
Can we get a few time comparisons on different size images created with imagedata? I would really like to see a chart of JUT versus non JIT.
This is actually very interesting, good work.
EDIT: Nevermind, I ran a little performance myself using this code, where I insert 30 million random numbers into a table:
Plain LOVE takes 8.31640625 seconds to complete the table.
LuaJIT LOVE takes 1.80859375 seconds to complete the table.
I have to say I heard using JIT was faster, but that is insane...
This is actually very interesting, good work.
EDIT: Nevermind, I ran a little performance myself using this code, where I insert 30 million random numbers into a table:
Code: Select all
function love.load()
numbers = {}
math.randomseed(os.time())
done = false
t1 = love.timer.getMicroTime( )
end
function love.update()
if not done then
for i = 1, 30000000 do
numbers[i] = math.random()
end
t2 = love.timer.getMicroTime()
done = true
end
end
function love.draw()
if done then
love.graphics.print("All Done!", 10, 10)
love.graphics.print("Time Taken: "..t2-t1, 10, 30)
end
end
LuaJIT LOVE takes 1.80859375 seconds to complete the table.
I have to say I heard using JIT was faster, but that is insane...
- BlackBulletIV
- Inner party member
- Posts: 1261
- Joined: Wed Dec 29, 2010 8:19 pm
- Location: Queensland, Australia
- Contact:
Re: LoveJIT
Wow, that's pretty awesome!Ensayia wrote:Plain LOVE takes 8.31640625 seconds to complete the table.
LuaJIT LOVE takes 1.80859375 seconds to complete the table.
Re: LoveJIT
Ooooo is that noise generated on the fly at 471fps?
Ensayia's code took 2 seconds with JIT, 14 seconds without..
Missing msvcr100.dll btw, can that be statically linked?
Ensayia's code took 2 seconds with JIT, 14 seconds without..
Missing msvcr100.dll btw, can that be statically linked?
- slime
- Solid Snayke
- Posts: 3166
- Joined: Mon Aug 23, 2010 6:45 am
- Location: Nova Scotia, Canada
- Contact:
Re: LoveJIT
I updated the windows zip so you (hopefully) won't need msvcr100.dll anymore.
The noise isn't generated at 471fps, that's just me drawing 2 512x512 images with a shitty video card.
LuaJIT's performance really shows when doing some heavy calculations in pure Lua code, for example this dynamic light demo runs at ~140fps without regular Lua and ~440fps with LuaJIT (and 300 vs 850 on my better video card). Things that are more graphically bound (example: drawing 100 different images in immediate mode) or crossing the Lua/C++ border a lot won't make much of a difference with LuaJIT vs regular Lua.
The noise isn't generated at 471fps, that's just me drawing 2 512x512 images with a shitty video card.
LuaJIT's performance really shows when doing some heavy calculations in pure Lua code, for example this dynamic light demo runs at ~140fps without regular Lua and ~440fps with LuaJIT (and 300 vs 850 on my better video card). Things that are more graphically bound (example: drawing 100 different images in immediate mode) or crossing the Lua/C++ border a lot won't make much of a difference with LuaJIT vs regular Lua.
Re: LoveJIT
Thank you for compiling love with LuaJIT.
My game desperately needed some JIT love.
My game desperately needed some JIT love.
- ishkabible
- Party member
- Posts: 241
- Joined: Sat Oct 23, 2010 7:34 pm
- Location: Kansas USA
Re: LoveJIT
nice, now i have an updated version of Love with LuaJIT thanks!!
edit:
dose this have FFI by chance?
edit2:
yes it dose!!! now im going to see if i can do something with this
edit:
dose this have FFI by chance?
edit2:
yes it dose!!! now im going to see if i can do something with this
Re: LoveJIT
This is to awesome to be true!
Aren't there any downsides?
Aren't there any downsides?
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: LoveJIT
No, you only need to sell your soul. I wasn't using mine anyway.Chief wrote:Aren't there any downsides?
Help us help you: attach a .love.
Re: LoveJIT
Because it's still in development there's always the probability of hard-to-track bugs. I once found one that ignored the first value in the table constructor in a very specific condition.Chief wrote:Aren't there any downsides?
On x86 systems without SSE2 it falls back to the interpreter.
And it's targeting specific architectures and (generic?) PPC is not one of them.
Shallow indentations.
Who is online
Users browsing this forum: Ahrefs [Bot], Bing [Bot] and 0 guests