diff options
author | Richard Guenther <rguenther@suse.de> | 2007-07-05 21:21:10 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2007-07-05 21:21:10 +0000 |
commit | e11e491dbfa0d4b134e653647a0bf1b645e17327 (patch) | |
tree | b8b99cf6b54105440df3df5219090d25018ce180 /gcc/tree-ssa.c | |
parent | f6cdc43257653ea4aeff8554f3e1ba48cd0e2dfe (diff) | |
download | gcc-e11e491dbfa0d4b134e653647a0bf1b645e17327.zip gcc-e11e491dbfa0d4b134e653647a0bf1b645e17327.tar.gz gcc-e11e491dbfa0d4b134e653647a0bf1b645e17327.tar.bz2 |
re PR middle-end/32639 (ptrmem1.C now ICE's on mainline)
2007-07-05 Richard Guenther <rguenther@suse.de>
PR middle-end/32639
* alias.c (get_alias_set): Tread METHOD_TYPE the same as
FUNCTION_TYPE.
* tree-ssa.c (useless_type_conversion_p): Check canonical
types early.
From-SVN: r126389
Diffstat (limited to 'gcc/tree-ssa.c')
-rw-r--r-- | gcc/tree-ssa.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/tree-ssa.c b/gcc/tree-ssa.c index 005d3fd..5e16652 100644 --- a/gcc/tree-ssa.c +++ b/gcc/tree-ssa.c @@ -920,6 +920,11 @@ useless_type_conversion_p (tree outer_type, tree inner_type) if (inner_type == outer_type) return true; + /* If we know the canonical types, compare them. */ + if (TYPE_CANONICAL (inner_type) + && TYPE_CANONICAL (inner_type) == TYPE_CANONICAL (outer_type)) + return true; + /* Changes in machine mode are never useless conversions. */ if (TYPE_MODE (inner_type) != TYPE_MODE (outer_type)) return false; @@ -1029,11 +1034,6 @@ useless_type_conversion_p (tree outer_type, tree inner_type) if (TREE_CODE (inner_type) != TREE_CODE (outer_type)) return false; - /* If we know the canonical types, compare them. */ - if (TYPE_CANONICAL (inner_type) - && TYPE_CANONICAL (inner_type) == TYPE_CANONICAL (outer_type)) - return true; - /* ??? Add structural equivalence check. */ /* ??? This should eventually just return false. */ |