qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 2/5] qemu_coroutine_self should not be marked co


From: Gabriel Kerneis
Subject: Re: [Qemu-devel] [PATCH 2/5] qemu_coroutine_self should not be marked coroutine_fn as it cannot yield
Date: Thu, 8 Aug 2013 10:12:31 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Thu, Aug 08, 2013 at 10:10:18AM +0100, Charlie Shepherd wrote:
> >Note that qemu_coroutine_self() in principle really needs to be annotated
> >coroutine_fn since it accesses (and returns) its execution context. The fact
> >that it is implemented with thread-local variables in Qemu is an 
> >implementation
> >detail, almost a hack (however smart); the "natural" CPC way would be to just
> >return the coroutine associated with the current continuation. So keeping the
> >annotation definitely makes sense.
> 
> While that would be the natural way, we are going to need the thread
> local variables regardless due to the use of the "leader" coroutine
> I believe (Stefan is this correct?).

Sure. I was simply pointing out that from a "philosophical" point-of-view,
it makes more sense to keep it coroutine_fn.

-- 
Gabriel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]