[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: LuaJIT FFI vs Lua binding vs Lua interface
- From: James McKaskill <james@...>
- Date: Fri, 22 Jun 2012 23:28:31 -0400
On Fri, Jun 22, 2012 at 4:54 AM, Miles Bader <firstname.lastname@example.org>
calls "strcmp" a bunch of times (on varying strings) in a loop. I
To get a bit better idea I tried the a simple benchmark that just
then wrote an equivalent "classic Lua C module", and tried that
too. I imagine this mostly measures the speed of the argument
marshalling etc in LuaFFI.
In this simple test LuaFFI didn't do too bad; the "classic Lua C
module" version is only about three times as fast as the "LuaFFI"
version (in LuaJIT, of course, the FFI benchmark is about 10 times
faster than the "classic Lua C module").
That's pretty decent in my books, considering I have spent no effort in trying to get luaffi fast so far. All the effort up to now has been for correctness.