This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC] completely peel loops unconditionally
On Wed, 16 Jun 2004, Richard Guenther wrote:
> Hi!
>
> This proof of concept patch enables complete loop peeling unconditionally
> (if -floop-optimize is specified, i.e. at -O1). This is most definitely
> always a win (but see below) and there is no way currently to only enable
> complete peeling without general peeling.
Uh oh, I seem to be confused about the logic in passes.c :/ I hope this
one gets a cleanup.
Otherwise the patch needs to be extended by
Index: passes.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/passes.c,v
retrieving revision 2.19
diff -u -c -3 -p -r2.19 passes.c
*** passes.c 16 Jun 2004 07:25:52 -0000 2.19
--- passes.c 16 Jun 2004 11:51:26 -0000
*************** rest_of_handle_loop2 (tree decl, rtx ins
*** 1378,1389 ****
if (decl != current_function_decl || insns != get_insns ())
abort ();
- if (!flag_unswitch_loops
- && !flag_peel_loops
- && !flag_unroll_loops
- && !flag_branch_on_count_reg)
- return;
-
timevar_push (TV_LOOP);
open_dump_file (DFI_loop2, decl);
if (dump_file)