This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[rtlopt] runtime iterations unrolling fix
- From: Jan Hubicka <jh at suse dot cz>
- To: gcc-patches at gcc dot gnu dot org, rakdver at atrey dot karlin dot mff dot cuni dot cz
- Date: Fri, 25 Oct 2002 23:35:43 +0200
- Subject: [rtlopt] runtime iterations unrolling fix
Zdenek,
the test to disable exit conditional in peeled copy of loop body is
reversed compared to the comment. I guess the comment is what
you've intended so I've changed it. Still I am not able to come with
testcase when we need exit test in all copies. Can you enlighten me?
(the testcase I was fixing was:
int a[100000];
int q = 267;
main ()
{
int i;
for (i = 0; i < q; i++)
a[i] = 0;
}
Honza
Fri Oct 25 23:32:09 CEST 2002 Jan Hubicka <jh@suse.cz>
* unroll.c (unroll_loop_runtime_iterations): Fix.
*** loop-unroll.c.old1 Sat Oct 26 01:44:17 2002
--- loop-unroll.c Sat Oct 26 01:43:45 2002
*************** unroll_loop_runtime_iterations (loops, l
*** 381,387 ****
number of iterations. Also, in case of postincrement we do
not know whether we should not exit before reaching the loop. */
sbitmap_zero (wont_exit);
! if (desc->postincr && (i || desc->cond == NE))
SET_BIT (wont_exit, 1);
if (!duplicate_loop_to_header_edge (loop, loop_preheader_edge (loop),
--- 381,387 ----
number of iterations. Also, in case of postincrement we do
not know whether we should not exit before reaching the loop. */
sbitmap_zero (wont_exit);
! if (!desc->postincr && (i || desc->cond == NE))
SET_BIT (wont_exit, 1);
if (!duplicate_loop_to_header_edge (loop, loop_preheader_edge (loop),