From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:34250) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS81a-0000aI-NO for qemu-devel@nongnu.org; Wed, 09 May 2012 10:37:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SS81W-0005ea-0f for qemu-devel@nongnu.org; Wed, 09 May 2012 10:37:54 -0400 Received: from mx1.redhat.com ([209.132.183.28]:8672) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS81V-0005eF-Oa for qemu-devel@nongnu.org; Wed, 09 May 2012 10:37:49 -0400 Message-ID: <4FAA8134.9060701@redhat.com> Date: Wed, 09 May 2012 17:37:40 +0300 From: Avi Kivity MIME-Version: 1.0 References: <4FA97596.4000807@siemens.com> <4FAA42EB.2080407@redhat.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] coroutine-ucontext broken for x86-32 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: Kevin Wolf , Jan Kiszka , Anthony Liguori , Michael Tokarev , qemu-devel On 05/09/2012 02:15 PM, Peter Maydell wrote: > I think it's becoming increasingly obvious that the setcontext/getcontext > code path is not very well used and prone to nasty libc bugs. Trying > to implement coroutines in C is just a really bad idea and I think > we should be trying to reduce our use of them if we possibly can, > presumably by switching to actually using threads where we really > need the parallelism. > I happen to like coroutines, but if we switch to threads, we should ensure that we eliminate the extra context switch if the layer below (usually posix-aio-compat) also uses threads. That leaves a theoretical regression with qcow2-on-native-aio, but that's a fairly rare use case. -- error compiling committee.c: too many arguments to function