diff options
author | dberlin <dberlin@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-07-15 23:50:52 +0000 |
---|---|---|
committer | dberlin <dberlin@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-07-15 23:50:52 +0000 |
commit | 7739c729cbb032edc59a9c37d2dbfb5293ea7087 (patch) | |
tree | 4faecb181c40f295369ac919f9ab5203eed115d8 /gcc/tree-ssa-sccvn.c | |
parent | 4971b9a8ba2016e1a41927b250e8802eb0787769 (diff) | |
download | gcc-7739c729cbb032edc59a9c37d2dbfb5293ea7087.tar.gz |
2008-07-15 Daniel Berlin <dberlin@dberlin.org>
* tree-ssa-sccvn.c (expressions_equal_p): Check type equality.
* tree-ssa-pre.c (pre_expr_eq): Ditto
(get_constant_for_value_id): Take a type as an argument.
(fully_constant_expression): Pass in type.
(find_or_generate_expression): Short circuit constant case.
(create_expression_by_pieces): Remove special casing of
pointer_plus.
(do_regular_insertion): Short circuit constant case.
(do_partial_partial_insertion): Ditto.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@137859 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-ssa-sccvn.c')
-rw-r--r-- | gcc/tree-ssa-sccvn.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/tree-ssa-sccvn.c b/gcc/tree-ssa-sccvn.c index f1318656b9b..69945a5c3c7 100644 --- a/gcc/tree-ssa-sccvn.c +++ b/gcc/tree-ssa-sccvn.c @@ -2582,6 +2582,8 @@ expressions_equal_p (tree e1, tree e2) te1 = TREE_TYPE (e1); te2 = TREE_TYPE (e2); + if (te1 != te2) + return false; if (TREE_CODE (e1) == TREE_LIST && TREE_CODE (e2) == TREE_LIST) { |