|
Le 22/04/2016 14:08, Viacheslav Usov a écrit :Not concurrently as this page explains : "The method above for implementing threading in Lua using a global mutex is inefficient on multiprocessor systems. As one thread holds the global mutex, other threads are waiting for it. Thus only one Lua thread may be running at a time, regardless of the number of processors in the system." So, if I have a long running thread, it will block others to run as well. The only way is to have a dedicated state per thread ... but my problem is to pass function reference to them. |