From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14381 invoked by alias); 31 Mar 2004 09:11:12 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 14356 invoked from network); 31 Mar 2004 09:11:11 -0000 Received: from unknown (HELO localhost.localdomain) (212.143.109.38) by sources.redhat.com with SMTP; 31 Mar 2004 09:11:11 -0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by localhost.localdomain (8.12.8/8.12.8) with ESMTP id i2V9BCKa016613; Wed, 31 Mar 2004 11:11:12 +0200 From: xyzzy@hotpop.com To: gcc@gcc.gnu.org Subject: Re: Backend port: Minimizing register usage in favor of memory accesses Date: Wed, 31 Mar 2004 12:23:00 -0000 User-Agent: KMail/1.6.1 References: <200403301148.19194.xyzzy@hotpop.com> <4069D937.9000507@specifixinc.com> In-Reply-To: <4069D937.9000507@specifixinc.com> Cc: Jim Wilson MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200403311111.08108.xyzzy@hotpop.com> X-SW-Source: 2004-03/txt/msg01756.txt.bz2 On Tuesday 30 March 2004 22:31, Jim Wilson wrote: > xyzzy@hotpop.com wrote: > > I understand that one of the goals of any optimizing compiler is to > > maximize use of registers since this is the fastest and least space > > consuming type of instruction on most processors. > > The goal of an optimizing compiler is to produce the fastest code for > the target. If the target wants registers to be used, then we use > registers. If the target doesn't want registers to be used, then we > don't use registers. > > > Is there any way to force the GCC backend to do this, if at all? > > We have been doing this since the beginning for an i386 target. Jim, thanks for the reply... Also, thanks to Joem. Can you point me in the right place to look in the i386 target so I don't mess this up? Is what Joem said about "lowering MEMORY_MOVE_COST" the only thing to do? Is there other black magic involved? Thanks again.