lua-users home
lua-l archive

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


on 10/18/04 7:18 PM, Mike Pall at mikelu-0410@mike.de wrote:

> The coroutine-on-top-of-coroutine solution demonstrated by Roberto may be
> ok for some cases. But it is definitely not feasible for my code due to
> the high overhead of creating and destroying millions of ultra-short
> running coroutines per second. This is not just a lightweight function call
> after all. :-(

One might be able to keep a stack of coroutines and recycle them. I do that
in some of my code but I haven't studied Roberto's code closely to see how
that would fit. Recycling basically depends on having the coroutine come
back around to a point where it waits for a new routine to execute.

Mark