lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Sat, Sep 25, 2010 at 01:20, Rebel Neurofog <rebelneurofog@gmail.com> wrote:
> I've made some benchmarking. This may help you to decide which way
> fits your requipments.

> Take a look: http://lua-users.org/wiki/ObjectOrientationClosureApproach

You should probably add metatable-based approach to the benchmark.

Also you should measure object creation and method calls separately. For different kinds of objects one may be more important than another.

See here for example benchmark:

http://github.com/agladysh/luamarca/blob/master/bench/factory.lua

To run, clone repository, cd to it and run

./run_benchmark.sh bench/factory.lua 1e6

Alexander.