This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
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:
DD
Description: Text document
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |