This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/19698] [4.0 regression] Infinite loop in update_life_info
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Jan 2005 03:30:26 -0000
- Subject: [Bug middle-end/19698] [4.0 regression] Infinite loop in update_life_info
- References: <20050129191719.19698.schwab@suse.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-01-30 03:30 -------
And here is the interesting part, PRE does not move a redundant expression out of a loop (well it does
but it is only out of the inner most loop).
Confirmed, reduced testcase, doing -fno-tree-PRE causes us not to create the infinite loop but that is
because we are not pulling out the redundant expression out of the inner loop:
void FFT(int NumSamples, float *RealOut, float ar1)
{
int i, j, n;
int BlockSize, BlockEnd;
if (NumSamples <= 1)
__builtin_exit(1);
i = 0;
L1:
RealOut[i] = (RealOut == 0) ? 0.0 : RealOut[i];
i++;
if (NumSamples <= i) goto L1;
BlockEnd = 1;
for (BlockSize = 2; BlockSize <= NumSamples; BlockSize *=2)
{
float cm1 = __builtin_cosf(-1.0);
for (i = 0; i < NumSamples; i += BlockSize)
for (j = i, n = 0; n < BlockEnd; j++, n++)
RealOut[j] = cm1 * ar1;
BlockEnd = BlockSize;
}
}
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2005-01-30 03:30:25
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19698