aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Pop <sebastian.pop@amd.com>2011-02-02 15:52:08 +0000
committerSebastian Pop <spop@gcc.gnu.org>2011-02-02 15:52:08 +0000
commit14dd9aabd6cdb21bd3c482452239f06230be84c3 (patch)
tree6ae2edc779700679f7e82d5fa0869260ee9418e2
parentd46efcfe977c4ccde0f70bf9bce3500ac740745b (diff)
downloadgcc-14dd9aabd6cdb21bd3c482452239f06230be84c3.zip
gcc-14dd9aabd6cdb21bd3c482452239f06230be84c3.tar.gz
gcc-14dd9aabd6cdb21bd3c482452239f06230be84c3.tar.bz2
Fix PR47576 and PR47555: add PARAM_SCEV_MAX_EXPR_COMPLEXITY.
2011-02-02 Sebastian Pop <sebastian.pop@amd.com> PR tree-optimization/47576 PR tree-optimization/47555 * doc/invoke.texi (scev-max-expr-complexity): Documented. * params.def (PARAM_SCEV_MAX_EXPR_SIZE): Bump the value to 100. (PARAM_SCEV_MAX_EXPR_COMPLEXITY): Declared. * tree-scalar-evolution.c (follow_ssa_edge): Use PARAM_SCEV_MAX_EXPR_COMPLEXITY. From-SVN: r169530
-rw-r--r--gcc/ChangeLog10
-rw-r--r--gcc/doc/invoke.texi4
-rw-r--r--gcc/params.def7
-rw-r--r--gcc/tree-scalar-evolution.c2
4 files changed, 21 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 2af2c32..cbe95a0 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,13 @@
+2011-02-02 Sebastian Pop <sebastian.pop@amd.com>
+
+ PR tree-optimization/47576
+ PR tree-optimization/47555
+ * doc/invoke.texi (scev-max-expr-complexity): Documented.
+ * params.def (PARAM_SCEV_MAX_EXPR_SIZE): Bump the value to 100.
+ (PARAM_SCEV_MAX_EXPR_COMPLEXITY): Declared.
+ * tree-scalar-evolution.c (follow_ssa_edge): Use
+ PARAM_SCEV_MAX_EXPR_COMPLEXITY.
+
2011-02-02 Richard Guenther <rguenther@suse.de>
PR tree-optimization/47566
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index b25d8cf..da226dc 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -8463,6 +8463,10 @@ optimization when a new iv is added to the set.
Bound on size of expressions used in the scalar evolutions analyzer.
Large expressions slow the analyzer.
+@item scev-max-expr-complexity
+Bound on the complexity of the expressions in the scalar evolutions analyzer.
+Complex expressions slow the analyzer.
+
@item omega-max-vars
The maximum number of variables in an Omega constraint system.
The default value is 128.
diff --git a/gcc/params.def b/gcc/params.def
index 3138bc2..5749eb2 100644
--- a/gcc/params.def
+++ b/gcc/params.def
@@ -481,7 +481,12 @@ DEFPARAM(PARAM_IV_ALWAYS_PRUNE_CAND_SET_BOUND,
DEFPARAM(PARAM_SCEV_MAX_EXPR_SIZE,
"scev-max-expr-size",
"Bound on size of expressions used in the scalar evolutions analyzer",
- 20, 0, 0)
+ 100, 0, 0)
+
+DEFPARAM(PARAM_SCEV_MAX_EXPR_COMPLEXITY,
+ "scev-max-expr-complexity",
+ "Bound on the complexity of the expressions in the scalar evolutions analyzer",
+ 10, 0, 0)
DEFPARAM(PARAM_OMEGA_MAX_VARS,
"omega-max-vars",
diff --git a/gcc/tree-scalar-evolution.c b/gcc/tree-scalar-evolution.c
index d60e569..1b68b36 100644
--- a/gcc/tree-scalar-evolution.c
+++ b/gcc/tree-scalar-evolution.c
@@ -1399,7 +1399,7 @@ follow_ssa_edge (struct loop *loop, gimple def, gimple halting_phi,
return t_false;
/* Give up if the path is longer than the MAX that we allow. */
- if (limit > PARAM_VALUE (PARAM_SCEV_MAX_EXPR_SIZE))
+ if (limit > PARAM_VALUE (PARAM_SCEV_MAX_EXPR_COMPLEXITY))
return t_dont_know;
def_loop = loop_containing_stmt (def);