[Bug ipa/65270] [5 regression] ICF needs to match TYPE attributes on memory accesses

hubicka at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Mar 2 18:25:00 GMT 2015


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65270

--- Comment #5 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
Thanks for looking into this! I think this was just the most obvoious of TYPE
flags. Some more we need to look into:

Is the alias class compare enough to handle TYPE_RESTRICT?

We probably want to match TYPE_ADDR_SPACE of accesses as that affect codegen?

We apparently need to match TYPE_ATTRIBUTES on functions, because we check that
flags on calees so we can not freely redirect them. Will fix that.

Also I think TYPE_STRING_FLAG may affect expand_builtin_classify_type that
probably ought to be done at folding time during early opts?

TYPE_NEEDS_CONSTRUCTING is used by ipa-pure-const but I think the use is wrong
(i.e. if decl needs to be constructed we will drop the readonly flag)

TYPE_NONALIASED_COMPONENT seems to affect alias.c in some way.

TYPE_FINAL_P also can not be mixed in virtual tables.



More information about the Gcc-bugs mailing list