From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CGwnp-0006iF-BT for qemu-devel@nongnu.org; Mon, 11 Oct 2004 05:49:13 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CGwno-0006hl-CE for qemu-devel@nongnu.org; Mon, 11 Oct 2004 05:49:12 -0400 Received: from [129.104.30.34] (helo=a.mx.polytechnique.org) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CGwgX-0006Wl-A2 for qemu-devel@nongnu.org; Mon, 11 Oct 2004 05:41:41 -0400 Received: from localhost (localhost [127.0.0.1]) by djali.polytechnique.org (Postfix) with ESMTP id 94B0D33284 for ; Mon, 11 Oct 2004 11:41:39 +0200 (CEST) Received: from djali.polytechnique.org ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 28456-05 for ; Mon, 11 Oct 2004 11:41:39 +0200 (CEST) Received: from [172.17.17.9] (gw.netgem.com [195.68.2.34]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ssl.polytechnique.org (Postfix) with ESMTP id 2EEA733278 for ; Mon, 11 Oct 2004 11:41:39 +0200 (CEST) Message-ID: <416A5551.9080703@bellard.org> Date: Mon, 11 Oct 2004 11:41:37 +0200 From: Fabrice Bellard MIME-Version: 1.0 Subject: Re: [Qemu-devel] env in TLS References: <20041011083228.6907.qmail@web52501.mail.yahoo.com> In-Reply-To: <20041011083228.6907.qmail@web52501.mail.yahoo.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit 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 Using TLS seems a good idea. I hesitated to implement it because I was not sure that segment overrides were as fast as an indexed memory access on all x86 processors. I think that imposing a gcc version >= 3.2 is no longer an issue. We must be sure that the other platforms support the __thread keyword though. Fabrice. Piotr Krysik wrote: > Hi! > > Fabrice, how about moving env variable to TLS? > > This could improve performance (based on > http://lists.gnu.org/archive/html/qemu-devel/2004-09/msg00294.html > > about 10% could be gained -- need to verify). Also > additional register would be available for op.c > (anyone to implement register renaming?). > > The main problem with this approach is portability. > AFAIK GCC <= 3.2 doesn't recognize __thread keyword. > For x86 we could fall-back to the LDT method from > qemu-fast. How about other platforms? In the worst > case we could use global variable and forget about > multi-processor qemu-softmmu and multi-thread in > qemu-user for some platforms in the future. > > > Comments? > > Piotrek > > > __________________________________________________ > Do You Yahoo!? > Tired of spam? Yahoo! Mail has the best spam protection around > http://mail.yahoo.com > > > _______________________________________________ > Qemu-devel mailing list > Qemu-devel@nongnu.org > http://lists.nongnu.org/mailman/listinfo/qemu-devel > >