This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Remove bad comment in scan_paradoxical_subregs in reload1.c
- From: Jim Wilson <wilson at specifixinc dot com>
- To: Ian Lance Taylor <ian at wasabisystems dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 18 Feb 2004 19:47:20 -0800
- Subject: Re: Remove bad comment in scan_paradoxical_subregs in reload1.c
- References: <20040212193112.29586.qmail@gossamer.airs.com>
Ian Lance Taylor wrote:
I'm pretty sure that this documented restriction no longer exists.
I'm pretty sure that the current compiler will use such a register for
reload when it can. But I don't know how to prove it, so I'm not
going to propose modifying the documentation.
I don't think it is hard to prove this. I wrote an x86 testcase that
uses 6 register variables, compiled it with -O2, and 2 of them got used
for spill registers in reload. I think that clearly proves that the
restriction no longer exists.
* reload1.c (reload): Correct comment.
(scan_paradoxical_subregs): Remove #if 0 and old comment.
OK.
Please also delete the one sentence in extend.texi that claims these
registers are not used by reload.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com
int array[10][10][10];
int ga, gb, gc, gd, ges, ged;
void
sub (void)
{
register int a __asm__ ("%eax");
register int b __asm__ ("%ebx");
register int c __asm__ ("%ecx");
register int d __asm__ ("%edx");
register int es __asm__ ("%esi");
register int ed __asm__ ("%edi");
a = ga;
b = gb;
c = gc;
d = gd;
es = ges;
ed = ged;
array[a][b][c] = array[d][es][ed];
}