[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: LuaJIT2 performance for number crunching
- From: Leo Razoumov <slonik.az@...>
- Date: Thu, 17 Feb 2011 10:50:14 -0500
On Thu, Feb 17, 2011 at 05:26, T T <t34www@googlemail.com> wrote:
> On 17 February 2011 10:00, steve donovan <steve.j.donovan@gmail.com> wrote:
>> On Thu, Feb 17, 2011 at 11:48 AM, T T <t34www@googlemail.com> wrote:
>>> vec3 = vec1 + vec2
>>>
>>> to add together two arrays and the good elves take care of the rest,
>>> but in Lua we have to write loops.
>>
>> Well, it's traditionally done with objects, and this creates a great
>> deal of garbage (I recall Leo talking about this very thing.) The
>> elves turn out to be quite expensive.
>
> MATLAB implements those quite efficiently, but that besides the point
> of this discussion.
Actually these good elves are called BLAS (and for certain operations
LAPACK) that MATLAB uses internally. Vectorization only happens with
built-in containers such as vectors and matrices. For user defined
types the recommended way to boost performance involves implementing
everything in C and hooking into MATLAB with mx interface.
As far as the MATLAB interpreter/JIT is concerned it is hopelessly
slow so that using MATLAB in event-driven simulations that require
explicit loops and lots of branching is PITA.
IMHO, the best thing that could happen to MATLAB is to switch to Lua,
license Mike's LuaJIT and port their cool toolboxes to it.
--Leo--
- References:
- Re: LuaJIT2 performance for number crunching, Florian Weimer
- Re: LuaJIT2 performance for number crunching, Francesco Abbate
- Re: LuaJIT2 performance for number crunching, Leo Razoumov
- Re: LuaJIT2 performance for number crunching, Francesco Abbate
- Re: LuaJIT2 performance for number crunching, Leo Razoumov
- Re: LuaJIT2 performance for number crunching, Francesco Abbate
- Re: LuaJIT2 performance for number crunching, Leo Razoumov
- Re: LuaJIT2 performance for number crunching, Francesco Abbate
- Re: LuaJIT2 performance for number crunching, T T
- Re: LuaJIT2 performance for number crunching, Daurnimator
- Re: LuaJIT2 performance for number crunching, Mike Pall
- Re: LuaJIT2 performance for number crunching, Philippe Lhoste
- Re: LuaJIT2 performance for number crunching, Alexander Gladysh
- Re: LuaJIT2 performance for number crunching, Miles Bader
- Re: LuaJIT2 performance for number crunching, T T
- Re: LuaJIT2 performance for number crunching, steve donovan
- Re: LuaJIT2 performance for number crunching, T T