aboutsummaryrefslogtreecommitdiff
path: root/gcc/ipa-icf.c
diff options
context:
space:
mode:
authorJan Hubicka <hubicka@ucw.cz>2015-11-21 04:57:48 +0100
committerJan Hubicka <hubicka@gcc.gnu.org>2015-11-21 03:57:48 +0000
commit5e83f17dd01ab8f4b12b82588fdd7f75a9cd5650 (patch)
treea975c099504f1b5234058364c3c726a01923b4b2 /gcc/ipa-icf.c
parent65310691f80bb61e561f34d7500cd6336d625f49 (diff)
downloadgcc-5e83f17dd01ab8f4b12b82588fdd7f75a9cd5650.zip
gcc-5e83f17dd01ab8f4b12b82588fdd7f75a9cd5650.tar.gz
gcc-5e83f17dd01ab8f4b12b82588fdd7f75a9cd5650.tar.bz2
ipa-icf.c (sem_item::add_type): Do not look for TYPE_CANONICAL...
* ipa-icf.c (sem_item::add_type): Do not look for TYPE_CANONICAL; do not check AGGREGATE_TYPE_P when adding TYPE_MODE; Check that all record types are complete. * ipa-icf-gimple.c (func_checker::compatible_types_p): Do not compare alias sets for types w/o alias sets. From-SVN: r230698
Diffstat (limited to 'gcc/ipa-icf.c')
-rw-r--r--gcc/ipa-icf.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/ipa-icf.c b/gcc/ipa-icf.c
index bf1acae..0c76672 100644
--- a/gcc/ipa-icf.c
+++ b/gcc/ipa-icf.c
@@ -1543,11 +1543,8 @@ sem_item::add_type (const_tree type, inchash::hash &hstate)
}
type = TYPE_MAIN_VARIANT (type);
- if (TYPE_CANONICAL (type))
- type = TYPE_CANONICAL (type);
- if (!AGGREGATE_TYPE_P (type))
- hstate.add_int (TYPE_MODE (type));
+ hstate.add_int (TYPE_MODE (type));
if (TREE_CODE (type) == COMPLEX_TYPE)
{
@@ -1574,6 +1571,7 @@ sem_item::add_type (const_tree type, inchash::hash &hstate)
}
else if (RECORD_OR_UNION_TYPE_P (type))
{
+ gcc_checking_assert (COMPLETE_TYPE_P (type));
hashval_t *val = optimizer->m_type_hash_cache.get (type);
if (!val)