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: int_cst_hash_table mapping persistence and the garbage collector


2011/10/13 Gary Funck <gary@intrepid.com>:
> On 10/13/11 06:15:31, Laurynas Biveinis wrote:
>> [...] In your case (correct me if I misunderstood something)
>> you have one hash table, marking of which will mark more objects
>> which are required for the correct marking of the second hash table.
>> GC might be simply walking the second one first.
>
> Yes, I think that this accurately summarizes the situation, and the result.
>
> Any suggestions on how to fix this? ÂIt seems that one fix might
> be to use a non garbage-collected hash table for the hash map.

Is it feasible to write an if_marked function for the second hash
table that would duplicate the work of the first hash table function
and then some? I.e. it would determine if an entry needs to be marked
based on information outside of both hash tables and independently of
the first one (even if duplicating its logic).


-- 
Laurynas


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