From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Gc44S-0000QT-Sa for qemu-devel@nongnu.org; Mon, 23 Oct 2006 13:58:44 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Gc44O-0000Np-40 for qemu-devel@nongnu.org; Mon, 23 Oct 2006 13:58:44 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Gc44N-0000NK-K6 for qemu-devel@nongnu.org; Mon, 23 Oct 2006 13:58:39 -0400 Received: from [65.74.133.4] (helo=mail.codesourcery.com) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1Gc44N-0001yL-8p for qemu-devel@nongnu.org; Mon, 23 Oct 2006 13:58:39 -0400 From: Paul Brook Subject: Re: [Qemu-devel] qemu vs gcc4 Date: Mon, 23 Oct 2006 18:58:29 +0100 References: <45391B22.1050608@palmsource.com> <56d259a00610230116p33e13e32i9b82f1e8f0871f27@mail.gmail.com> <453CFED8.2020402@palmsource.com> In-Reply-To: <453CFED8.2020402@palmsource.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200610231858.32157.paul@codesourcery.com> 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 On Monday 23 October 2006 18:41, K. Richard Pixley wrote: > Martin Guy wrote: > >> Now, gcc4 can produce code with several return instructions (with no > >> option to turn that of, as far as I understand). You cannot cut them > >> out, > >> and therefore you cannot chain the simple functions. > > > > ...unless you also map return instructions within the generated > > functions into branches to the soon-to-be-dropped final "return"? Not > > that I know anything about qemu internals mind u... > > Seems to me one could also map them into jumps to a null function. That doesn't work because you need to free the stack frame. > Although, all told, it would seem to me that what might be called for > here is a new gcc target. A gcc target specifically for generating qemu > code. That would just simply generate whatever qemu wanted for function > postamble. Better to just teach qemu how to generate code. In fact I've already done most of the infrastructure (and a fair amount of the legwork) for this. The only major missing function is code to do softmmu load/store ops. https://nowt.dyndns.org/ Paul