From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Gc4OM-00041k-Eh for qemu-devel@nongnu.org; Mon, 23 Oct 2006 14:19:18 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Gc4OI-0003ye-Vl for qemu-devel@nongnu.org; Mon, 23 Oct 2006 14:19:17 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Gc4OH-0003yM-Vo for qemu-devel@nongnu.org; Mon, 23 Oct 2006 14:19:14 -0400 Received: from [193.252.23.69] (helo=smtp-msa-out14.orange.fr) by monty-python.gnu.org with esmtp (Exim 4.52) id 1Gc4OH-00057o-PK for qemu-devel@nongnu.org; Mon, 23 Oct 2006 14:19:14 -0400 Received: from [192.168.0.2] (ANice-251-1-84-191.w86-216.abo.wanadoo.fr [86.216.23.191]) by mwinf1403.orange.fr (SMTP Server) with ESMTP id 1491E700009D for ; Mon, 23 Oct 2006 20:19:11 +0200 (CEST) Message-ID: <453D07FF.1000401@wanadoo.fr> Date: Mon, 23 Oct 2006 20:20:47 +0200 From: Laurent Desnogues MIME-Version: 1.0 Subject: Re: [Qemu-devel] qemu vs gcc4 References: <45391B22.1050608@palmsource.com> <56d259a00610230116p33e13e32i9b82f1e8f0871f27@mail.gmail.com> <453CFED8.2020402@palmsource.com> <200610231858.32157.paul@codesourcery.com> <453D0428.9090809@palmsource.com> In-Reply-To: <453D0428.9090809@palmsource.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable 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 K. Richard Pixley a =E9crit : > Well, perhaps. Except that with gcc, we get to leverage the ongoing gc= c=20 > optimizations, bug fixes, new cpu support, debugger support, etc. =20 > Granted, not all of these are going to be relevant to the qemu=20 > environment, but in a contest between gcc generated code and qemu=20 > generated code, I'll bet on gcc most days. >=20 > No doubt there are times when a gcc optimization takes so long that it=20 > costs more time to optimize than would be won back by the running code.= =20 > Presumably, qemu generated code would be able to make better decisions=20 > here. Except that we're not talking about using gcc in real time, are=20 > we? So essentially we have near infinite time for optimizations. One emulated instruction is a small C function with very little opportunity for optimization. On top of that, for instance, calculating flags can be done much more efficiently at assembly level by using host flags. All what gcc brings here is portability. Laurent