From acf5dbc0b7780759d8291a43195df00b4d88c28e Mon Sep 17 00:00:00 2001 From: rguenth Date: Thu, 2 Dec 2010 16:26:22 +0000 Subject: [PATCH] 2010-12-02 Richard Guenther * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Disregard sign-changing conversions for induction detection. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@167378 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 5 +++++ gcc/tree-vect-loop.c | 2 ++ 2 files changed, 7 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index bde5e91..3241bbd 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,10 @@ 2010-12-02 Richard Guenther + * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Disregard + sign-changing conversions for induction detection. + +2010-12-02 Richard Guenther + PR tree-optimization/46723 * tree-vect-loop.c (get_initial_def_for_induction): Strip conversions from the induction evolution and apply it to diff --git a/gcc/tree-vect-loop.c b/gcc/tree-vect-loop.c index 7a562b1..3aa77d6 100644 --- a/gcc/tree-vect-loop.c +++ b/gcc/tree-vect-loop.c @@ -478,6 +478,8 @@ vect_analyze_scalar_cycles_1 (loop_vec_info loop_vinfo, struct loop *loop) /* Analyze the evolution function. */ access_fn = analyze_scalar_evolution (loop, def); + if (access_fn) + STRIP_NOPS (access_fn); if (access_fn && vect_print_dump_info (REPORT_DETAILS)) { fprintf (vect_dump, "Access function of PHI: "); -- 2.7.4