This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH to TYPE_HASH


Jason Merrill <jason@redhat.com> writes:

> On Fri, 05 Mar 2004 15:12:15 -0800, Zack Weinberg <zack@codesourcery.com> wrote:
>
>> Jason Merrill <jason@redhat.com> writes:
>>
>>> As previously mentioned, the canonical type hash table doesn't work
>>> very well with PCH because the hash codes are based on tree
>>> addresses which are not consistent over PCH save and load.  This
>>> patch changes TYPE_HASH to use TYPE_UID instead of the address.
>>
>> Please don't; I intend(ed) to kill TYPE_UID.
>
> Well, then it seems to me that you get to come up with another solution for
> hashing types across PCH.  This strategy is what Geoff suggested.

Two possibilities come immediately to mind:

1) Fix PCH so it's robust in the face of pointer hashing.
2) Hash *content*, not address or UIDs.

Thoughts?

zw


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]