common.opt (ftree-loop-ivcanon): Enable by default.
* common.opt (ftree-loop-ivcanon): Enable by default. * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Enable complete loop unrolling. (canonicalize_induction_variables, tree_unroll_loops_completely): Reset scev info. * gcc.dg/tree-ssa/loop-1.c: Check that unrolling occurs already on tree level. From-SVN: r88404
This commit is contained in:
parent
734268f590
commit
47bcd07d56
|
@ -1,3 +1,11 @@
|
|||
2004-10-01 Zdenek Dvorak <dvorakz@suse.cz>
|
||||
|
||||
* common.opt (ftree-loop-ivcanon): Enable by default.
|
||||
* tree-ssa-loop-ivcanon.c (try_unroll_loop_completely):
|
||||
Enable complete loop unrolling.
|
||||
(canonicalize_induction_variables, tree_unroll_loops_completely):
|
||||
Reset scev info.
|
||||
|
||||
2004-01-01 Paul Brook <paul@codesourcery.com>
|
||||
|
||||
* config/arm/arm.c (thumb_compute_saved_rag_mask): Or with bitmask,
|
||||
|
|
|
@ -857,7 +857,7 @@ Common Report Var(flag_tree_loop_linear)
|
|||
Enable linear loop transforms on trees
|
||||
|
||||
ftree-loop-ivcanon
|
||||
Common Report Var(flag_tree_loop_ivcanon)
|
||||
Common Report Var(flag_tree_loop_ivcanon) Init(1)
|
||||
Create canonical induction variables in loops
|
||||
|
||||
ftree-loop-optimize
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2004-10-01 Zdenek Dvorak <dvorakz@suse.cz>
|
||||
|
||||
* gcc.dg/tree-ssa/loop-1.c: Check that unrolling occurs already on
|
||||
tree level.
|
||||
|
||||
2004-10-01 Andrew Pinski <pinskia@physics.uc.edu>
|
||||
|
||||
* gcc.dg/tree-ssa/pr17343.c: Remove.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/* { dg-do compile } */
|
||||
/* { dg-options "-O1 -ftree-loop-ivcanon -funroll-loops -fdump-tree-ivcanon-details" } */
|
||||
/* { dg-options "-O1 -ftree-loop-ivcanon -funroll-loops -fdump-tree-ivcanon-details -fdump-tree-cunroll-details -fdump-tree-vars" } */
|
||||
|
||||
/* On 31-bit S/390 the function address will be stored (once) in the literal pool,
|
||||
so scan-assembler-times "foo" will return 1 even if the loop is fully unrolled.
|
||||
|
@ -17,6 +17,8 @@ void xxx(void)
|
|||
/* We should be able to find out that the loop iterates four times and unroll it completely. */
|
||||
|
||||
/* { dg-final { scan-tree-dump-times "Added canonical iv to loop 1, 4 iterations" 1 "ivcanon"} } */
|
||||
/* { dg-final { scan-tree-dump-times "Unrolled loop 1 completely" 1 "cunroll"} } */
|
||||
/* { dg-final { scan-tree-dump-times "foo" 5 "vars"} } */
|
||||
/* { dg-final { scan-assembler-times "foo" 5} } */
|
||||
|
||||
|
||||
|
|
|
@ -175,12 +175,9 @@ try_unroll_loop_completely (struct loops *loops ATTRIBUTE_UNUSED,
|
|||
COND_EXPR_COND (cond) = dont_exit;
|
||||
modify_stmt (cond);
|
||||
|
||||
#if 0
|
||||
/* The necessary infrastructure is not in yet. */
|
||||
if (!tree_duplicate_loop_to_header_edge (loop, loop_preheader_edge (loop),
|
||||
loops, n_unroll, NULL,
|
||||
NULL, NULL, NULL, 0))
|
||||
#endif
|
||||
{
|
||||
COND_EXPR_COND (cond) = old_cond;
|
||||
return false;
|
||||
|
@ -263,6 +260,10 @@ canonicalize_induction_variables (struct loops *loops)
|
|||
canonicalize_loop_induction_variables (loops, loop, true, false, true);
|
||||
}
|
||||
|
||||
/* Clean up the information about numbers of iterations, since brute force
|
||||
evaluation could reveal new information. */
|
||||
scev_reset ();
|
||||
|
||||
#if 0
|
||||
/* The necessary infrastructure is not in yet. */
|
||||
if (changed)
|
||||
|
@ -291,6 +292,10 @@ tree_unroll_loops_completely (struct loops *loops)
|
|||
!flag_tree_loop_ivcanon);
|
||||
}
|
||||
|
||||
/* Clean up the information about numbers of iterations, since complete
|
||||
unrolling might have invalidated it. */
|
||||
scev_reset ();
|
||||
|
||||
#if 0
|
||||
/* The necessary infrastructure is not in yet. */
|
||||
if (changed)
|
||||
|
|
Loading…
Reference in New Issue