This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: optimization/7130: miscompiled code for gcc-3.1 in powerpc linux with -funroll-all-loops
- From: Alan Modra <amodra at bigpond dot net dot au>
- To: gcc-patches at gcc dot gnu dot org
- Date: Thu, 11 Jul 2002 17:40:31 +0930
- Subject: Re: optimization/7130: miscompiled code for gcc-3.1 in powerpc linux with -funroll-all-loops
- References: <20020626010912.29465.qmail@sources.redhat.com> <20020711075156.GD30362@bubble.sa.bigpond.net.au>
On Thu, Jul 11, 2002 at 05:21:57PM +0930, Alan Modra wrote:
> Index: gcc/doloop.c
> - if (abs_inc != 1)
> - diff = expand_simple_binop (GET_MODE (diff), PLUS,
> - diff, GEN_INT (abs_inc - 1),
> - diff, 1, OPTAB_LIB_WIDEN);
> + diff = expand_simple_binop (GET_MODE (diff), PLUS,
> + diff, GEN_INT (abs_loop_inc - abs_inc),
> + diff, 1, OPTAB_LIB_WIDEN);
Small revision. The above isn't wrong, but I should be using
if (abs_loop_inc != abs_inc)
diff = expand_simple_binop (GET_MODE (diff), PLUS,
diff, GEN_INT (abs_loop_inc - abs_inc),
diff, 1, OPTAB_LIB_WIDEN);
--
Alan Modra
IBM OzLabs - Linux Technology Centre