[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cygwin
Subject:    Re: is three any coroutine library works in cygwin?
From:       Corinna Vinschen <corinna-cygwin () cygwin ! com>
Date:       2015-04-30 14:35:43
Message-ID: 20150430143543.GP3657 () calimero ! vinschen ! de
[Download RAW message or body]


On Apr 30 08:13, Eric Blake wrote:
> On 04/30/2015 08:02 AM, echo wrote:
> > My program is using coroutine(implemented with ucontext api) on linux, I
> > am trying to port it to windows using cygwin. But I find out that cygwin
> > doesn't support ucontext api, so is there any coroutine library works
> > fine in cygwin?
> 
> The qemu project has several alternative implementations for coroutines
> - in addition to ucontext, it provides sigaltstack, gthread, and win32
> implementations.  Perhaps one of those can be used as a starting point
> for your needs?  (see the coroutine-*.c files in
> http://git.qemu.org/?p=qemu.git;a=tree)

Cygwin 2.0 comes with improved ucontext handling in case of calling
signal handlers.  We might be able to come up with the missing functions
(getcontext, setcontext, makecontext, swapcontext, sigaltstack) at one
point, but that requires some hacking.

Patches are very welcome!


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[Attachment #3 (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic