[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: coroutine vs threads
- From: Javier Guerra Giraldez <javier@...>
- Date: Sun, 17 Jul 2011 14:29:15 -0500
On Sun, Jul 17, 2011 at 12:21 PM, Gaspard Bucher <gaspard@teti.ch> wrote:
> Thanks for the feedback. I looked at HTT and it looks really nice, but I
> have the feeling that I don't understand the benefit of a single event loop.
> I know that this is the common way to implement my event based architecture,
> but I don't understand why: it requires more complicated code, events
> starting in one place and finishing in another, data copying, queues,
> mutexes or complicated atomic code (for the event posting queue) and
> integrates badly with OS IO, interrupts and such....
you have it backwards: all these you mention is needed for
multithreaded code, not for single-thread, or coroutines
--
Javier