From f29deac9bd4ae965809d7735631f707e38b40f82 Mon Sep 17 00:00:00 2001 From: Sebastian Pop Date: Wed, 21 Oct 2009 23:05:39 +0000 Subject: re PR tree-optimization/41497 (apparent integer wrong code bug) PR tree-optimization/41497 * tree-scalar-evolution.c (analyze_evolution_in_loop): Return chrec_dont_know if the evolution function returned by follow_ssa_edge is constant in the analyzed loop and is not compatible with the initial value before the loop. * tree-chrec.h (no_evolution_in_loop_p): Call STRIP_NOPS. * gcc.dg/tree-ssa/pr41497.c: New. From-SVN: r153441 --- gcc/tree-chrec.h | 1 + 1 file changed, 1 insertion(+) (limited to 'gcc/tree-chrec.h') diff --git a/gcc/tree-chrec.h b/gcc/tree-chrec.h index f21aa74..545db38 100644 --- a/gcc/tree-chrec.h +++ b/gcc/tree-chrec.h @@ -115,6 +115,7 @@ no_evolution_in_loop_p (tree chrec, unsigned loop_num, bool *res) || chrec_contains_symbols_defined_in_loop (chrec, loop_num)) return false; + STRIP_NOPS (chrec); scev = hide_evolution_in_other_loops_than_loop (chrec, loop_num); *res = !tree_is_chrec (scev); return true; -- cgit v1.1