This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [lto] Re-implement pass_ipa_free_lang_specifics [3/3]
On Tue, Jan 20, 2009 at 11:31, Richard Guenther
<richard.guenther@gmail.com> wrote:
>> + if (TREE_CODE (f1) != TREE_CODE (f2)
>> + || DECL_NAME (f1) != DECL_NAME (f2))
>
> Uh, using DECL_NAME looks ... funny? Any reason to not use
>
> if (gimple_types_compatible_p (TREE_TYPE (f1), TREE_TYPE (f2))
>
> here?
>
>> + break;
>> + }
>> +
>> + return f1 && f2 ? 0 : 1;
>> + }
>> +
>> + return TYPE_MAIN_VARIANT (type1) == TYPE_MAIN_VARIANT (type2);
>
> shouldn't this honour TYPE_CANONICAL as well?
Thanks. Yes, I agree with both comments.
This is ancient code that I didn't want to change just yet, but will
likely need changes now that we are going to start using it
exclusively after pass_ipa_free_lang_data.
Diego.