From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NElit-0007RK-16 for qemu-devel@nongnu.org; Sun, 29 Nov 2009 10:30:03 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NElio-0007Qe-LG for qemu-devel@nongnu.org; Sun, 29 Nov 2009 10:30:02 -0500 Received: from [199.232.76.173] (port=38022 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NElio-0007Qb-FM for qemu-devel@nongnu.org; Sun, 29 Nov 2009 10:29:58 -0500 Received: from mx1.redhat.com ([209.132.183.28]:7517) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NElin-0001Hw-TZ for qemu-devel@nongnu.org; Sun, 29 Nov 2009 10:29:58 -0500 Message-ID: <4B129372.1070204@redhat.com> Date: Sun, 29 Nov 2009 17:29:54 +0200 From: Avi Kivity MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH 2/7] store thread-specific env information References: <1259256300-23937-1-git-send-email-glommer@redhat.com> <1259256300-23937-2-git-send-email-glommer@redhat.com> <1259256300-23937-3-git-send-email-glommer@redhat.com> In-Reply-To: <1259256300-23937-3-git-send-email-glommer@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Glauber Costa Cc: aliguori@us.ibm.com, qemu-devel@nongnu.org On 11/26/2009 07:24 PM, Glauber Costa wrote: > Since we'll have multiple cpu threads, at least for kvm, we need a way to store > and retrieve the CPUState associated with the current execution thread. > For the I/O thread, this will be NULL. > > I am using pthread functions for that, for portability, but we could as well > use __thread keyword. > > Where is __thread not supported? It's likely a bit faster than pthread_getspecific(). -- error compiling committee.c: too many arguments to function