[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: snapshot of Lua 4.1 (work)
- From: Edgar Toernig <froese@...>
- Date: Wed, 09 May 2001 21:06:20 +0200
Jean-Claude Wippler wrote:
> >We'd like to see implementations of coroutines and multithreads on top these.
> Is anyone doing this, or are you looking for a volunteer?
I'll definitely take a look. In Sol I already have a coroutine library
based on longjmp. But it requires knowledge about the structure of the
jmp_buf. I recently found the POSIX functions getcontext/makecontext/
swapcontext. I'll change Sol's coro-lib to depend on these functions
and add a prototype ucontext implementation for systems that do not have
these functions . I'll then port this lib to Lua 4.1.
 I actually don't know which systems offer these functions. They
are part of the POSIX standard but afaics not required. My system
at least does not have them (old Linux). It would be nice if someone
could tell me which system support them. Solaris? Win? Newer Linux?
Probably a look whether <ucontext.h> with prototypes for these functions
exists is enough...