Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LPyn8-0001mh-09 for qemu-devel@nongnu.org; Thu, 22 Jan 2009 07:36:14 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LPyn7-0001lP-A7 for qemu-devel@nongnu.org; Thu, 22 Jan 2009 07:36:13 -0500 Received: from [199.232.76.173] (port=43241 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LPyn7-0001kw-2z for qemu-devel@nongnu.org; Thu, 22 Jan 2009 07:36:13 -0500 Received: from smtp02.citrix.com ([66.165.176.63]:9961) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LPyn6-0003IK-P3 for qemu-devel@nongnu.org; Thu, 22 Jan 2009 07:36:12 -0500 Received: from mariner.uk.xensource.com ([10.80.2.22]) by smtp01.ad.xensource.com (8.13.1/8.13.1) with ESMTP id n0MCa91r022247 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO) for ; Thu, 22 Jan 2009 04:36:10 -0800 Received: from iwj by mariner.uk.xensource.com with local (Exim 4.63) (envelope-from ) id 1LPyn2-0002G5-1G for qemu-devel@nongnu.org; Thu, 22 Jan 2009 12:36:08 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <18808.26680.24696.223678@mariner.uk.xensource.com> Date: Thu, 22 Jan 2009 12:36:08 +0000 Subject: Re: [Qemu-devel] [6391] Fix nographic mode and VNC In-Reply-To: <200901220423.23551.paul@codesourcery.com> References: <200901220004.11338.paul@codesourcery.com> <4977E87A.5040904@codemonkey.ws> <200901220423.23551.paul@codesourcery.com> From: Ian Jackson Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Paul Brook writes ("Re: [Qemu-devel] [6391] Fix nographic mode and VNC"): > [Anthony:] > > The third possibility is to have the select() run in a separate thread > > from the TCG cpu_exec() loop. cpu_exec() would do an atomic read of > > 'event_pending' and the IO thread would do an atomic write of > > 'event_pending' whenever select() returned a writable file descriptor. > > This suffers from the same problem described above. You need to > force the main execution thread to break out of the translated > loop. In practice this probably means sending a signal to the main > thread. You could check event_pending at the start of every TB, but > that's likely to incur a fairly big performance hit. What would the signal handler do ? siglongjmp out of the translated loop ? Surely the timer implementation doesn't do that right now. Ian.