diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-06-06 19:27:55 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-06-06 19:27:55 +0000 |
commit | b74b821630d81d06cd6f46c510e81a52f6869943 (patch) | |
tree | f13f265ea9578f70210f9251b133e6fe4ad7334f | |
parent | 6349b54518420bfba40f1e19fa1e7ffdb690c787 (diff) | |
download | gcc-b74b821630d81d06cd6f46c510e81a52f6869943.tar.gz |
* tree-chrec.c (reset_evolution_in_loop): Use build3 instead of
build2.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@100675 138bc75d-0d04-0410-961f-82ee72b054a4
-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 2007efc983d..0bbc3a6afe2 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 bd8bafc9762..1a7e8c8c631 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); |