lua-users home
lua-l archive

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


Diego Nehab wrote:
However, there will always be someone asking: "Why doesn't
Lua have multi-threading support?"

Something tells me that trying to convince that person not
to use threads will cause him/her to use Python. :/

For Lua, I think the right answer belongs to David Given(if I remember
correctly). This means a lua state per OS thread and YAN thread
for communication between the states. The overhead is the xtra
memory for each state (but who cares it will be less than python)
and the data transfer between states (which has to happen anyway).
This model has one mutex for transferring data between states.
Above all this model is simple.

DB