From: Andrew MacLeod <amacleod@redhat.com>
To: "Vladimir N. Makarov" <vmakarov@redhat.com>
Cc: John Lu <jlu@lsil.com>, gcc mailing list <gcc@gcc.gnu.org>
Subject: Re: Register Allocation
Date: Fri, 26 Mar 2004 22:26:00 -0000 [thread overview]
Message-ID: <1080332310.12834.349.camel@p4> (raw)
In-Reply-To: <40648F84.5070704@redhat.com>
[-- Attachment #1: Type: text/plain, Size: 1287 bytes --]
On Fri, 2004-03-26 at 15:16, Vladimir N. Makarov wrote:
> John Lu wrote:
>
> >Hi,
> >
> >I've been working on a port based on gcc-3.3 and I've noticed that
> >better assembly code is generated if the C source has
> >separate variables declared for distinct live ranges.
> >
> >
> >
> Pesudo-register renaming is made by -fweb. It was written by Jan
> Hubicka. Probably, this option should be set up by default (although
> there is no practically improvement for SPECInt2000 for P4, some tests
> are really faster). Another positive thing of usage this option is
> better scheduling because of less anti-dependences.
>
tree-ssa will be doing this type of thing automatically shortly. Its a
one line patch to enable it. (attached). I haven't turned it on yet
because it can make a real mess of the debug information and we'd like
to fix that :-).
Andrew
PS. tree-ssa optimizes that program to:
foo1 (p1, p2)
{
int i.15;
int total;
int i;
<bb 0>:
total = 0;
i = 0;
<L0>:;
total = *((int *)((unsigned int)i * 4) + p1) + total;
i = i + 1;
if (i <= 99) goto <L0>; else goto <L12>;
<L12>:;
i.15 = 0;
<L6>:;
total = *((int *)((unsigned int)i.15 * 4) + p1) + total;
i.15 = i.15 + 2;
if (i.15 <= 99) goto <L6>; else goto <L5>;
<L5>:;
return total;
}
[-- Attachment #2: DD --]
[-- Type: text/plain, Size: 900 bytes --]
* tree-ssa (rewrite_out_of_ssa): Disable coalescing of variables not
related by a copy that share the same root variable.
Index: tree-outof-ssa.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/Attic/tree-outof-ssa.c,v
retrieving revision 1.1.2.1
diff -c -p -r1.1.2.1 tree-outof-ssa.c
*** tree-outof-ssa.c 19 Mar 2004 02:07:25 -0000 1.1.2.1
--- tree-outof-ssa.c 24 Mar 2004 19:56:28 -0000
*************** rewrite_out_of_ssa (void)
*** 1970,1977 ****
{
var_map map;
int var_flags = 0;
! int ssa_flags = (SSANORM_REMOVE_ALL_PHIS | SSANORM_USE_COALESCE_LIST
! | SSANORM_COALESCE_PARTITIONS);
eliminate_virtual_phis ();
--- 1970,1976 ----
{
var_map map;
int var_flags = 0;
! int ssa_flags = (SSANORM_REMOVE_ALL_PHIS | SSANORM_USE_COALESCE_LIST);
eliminate_virtual_phis ();
next prev parent reply other threads:[~2004-03-26 20:18 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-26 22:21 John Lu
2004-03-26 22:21 ` Vladimir N. Makarov
2004-03-26 22:26 ` Andrew MacLeod [this message]
2004-03-27 18:22 ` Andi Kleen
-- strict thread matches above, loose matches on Subject: below --
2010-12-23 8:13 register allocation roy rosen
2010-12-23 16:48 ` Vladimir Makarov
2010-12-23 17:22 ` Jeff Law
2010-12-27 15:43 ` roy rosen
2011-01-03 15:41 ` Jeff Law
2011-01-05 14:44 ` roy rosen
2011-01-05 15:26 ` Jeff Law
2011-01-11 16:11 ` Vladimir Makarov
2011-01-11 15:53 ` Vladimir Makarov
2005-11-24 20:51 Register Allocation Joern RENNECKE
2005-11-17 16:53 Andrew MacLeod
2005-11-18 2:55 ` Mark Mitchell
2005-11-18 3:27 ` Daniel Jacobowitz
2005-11-18 9:53 ` Giovanni Bajo
2005-11-18 15:28 ` Andrew MacLeod
2005-11-19 19:31 ` Ian Lance Taylor
2005-11-19 20:20 ` Denis Chertykov
2005-11-20 0:20 ` Giovanni Bajo
2005-11-23 17:07 ` Andrew MacLeod
2005-11-23 20:43 ` Ian Lance Taylor
2005-11-20 0:37 ` Steven Bosscher
2005-11-23 17:08 ` Andrew MacLeod
2005-11-22 19:26 ` Peter Bergner
2005-11-22 21:55 ` Steven Bosscher
[not found] ` <200511222256.13823.>
2005-11-22 22:58 ` Peter Bergner
2005-11-23 14:06 ` Michael Matz
2005-11-23 20:50 ` Peter Bergner
2005-11-23 17:08 ` Andrew MacLeod
2004-09-22 1:21 Adrian Strätling
2004-09-22 5:22 ` tm_gccmail
2004-10-04 14:13 ` Nick Ing-Simmons
2004-05-02 13:27 register allocation Qiong Cai
2004-05-02 16:56 ` Daniel Berlin
2004-05-03 7:07 ` Michael Matz
2002-03-12 6:21 register Allocation Danish Samad
1997-10-14 5:51 Register allocation Thomas Koenig
1998-12-21 22:38 ` Jeffrey A Law
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1080332310.12834.349.camel@p4 \
--to=amacleod@redhat.com \
--cc=gcc@gcc.gnu.org \
--cc=jlu@lsil.com \
--cc=vmakarov@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).