diff options
author | Jakub Jelinek <jakub@redhat.com> | 2005-06-06 21:27:55 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2005-06-06 21:27:55 +0200 |
commit | 6be74c4f5c988270ef3e4d4664a15b2b2e205f9a (patch) | |
tree | f13f265ea9578f70210f9251b133e6fe4ad7334f | |
parent | 40182dbff7fe0f85becc57d2fb0009289558bd46 (diff) | |
download | gcc-6be74c4f5c988270ef3e4d4664a15b2b2e205f9a.zip gcc-6be74c4f5c988270ef3e4d4664a15b2b2e205f9a.tar.gz gcc-6be74c4f5c988270ef3e4d4664a15b2b2e205f9a.tar.bz2 |
tree-chrec.c (reset_evolution_in_loop): Use build3 instead of build2.
* tree-chrec.c (reset_evolution_in_loop): Use build3 instead of
build2.
From-SVN: r100675
-rw-r--r-- | gcc/ChangeLog | 3 | ||||
-rw-r--r-- | gcc/tree-chrec.c | 16 |
2 files changed, 13 insertions, 6 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 2007efc..0bbc3a6 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,8 @@ 2005-06-06 Jakub Jelinek <jakub@redhat.com> + * tree-chrec.c (reset_evolution_in_loop): Use build3 instead of + build2. + * fold-const.c (operand_equal_p): Don't return 1, if element chains for 2 VECTOR_CSTs are not the same length. diff --git a/gcc/tree-chrec.c b/gcc/tree-chrec.c index bd8bafc..1a7e8c8 100644 --- a/gcc/tree-chrec.c +++ b/gcc/tree-chrec.c @@ -725,12 +725,16 @@ reset_evolution_in_loop (unsigned loop_num, { if (TREE_CODE (chrec) == POLYNOMIAL_CHREC && CHREC_VARIABLE (chrec) > loop_num) - return build2 - (TREE_CODE (chrec), - build_int_cst (NULL_TREE, CHREC_VARIABLE (chrec)), - reset_evolution_in_loop (loop_num, CHREC_LEFT (chrec), new_evol), - reset_evolution_in_loop (loop_num, CHREC_RIGHT (chrec), new_evol)); - + { + tree left = reset_evolution_in_loop (loop_num, CHREC_LEFT (chrec), + new_evol); + tree right = reset_evolution_in_loop (loop_num, CHREC_RIGHT (chrec), + new_evol); + return build3 (POLYNOMIAL_CHREC, TREE_TYPE (left), + build_int_cst (NULL_TREE, CHREC_VARIABLE (chrec)), + left, right); + } + while (TREE_CODE (chrec) == POLYNOMIAL_CHREC && CHREC_VARIABLE (chrec) == loop_num) chrec = CHREC_LEFT (chrec); |