On Sun, Jul 12, 2015 at 5:58 PM, Tom de Vries <tom_devr...@mentor.com> wrote:
> On 12/07/15 17:45, Tom de Vries wrote:
>>
>> Hi,
>>
>> this patch series implements the forbidding of multi-step garbage
>> collection liveness dependencies between caches.
>>
>> The first four patches downgrade 3 caches to non-cache, since they
>> introduce multi-step dependencies. This allows us to decouple:
>> - establishing a policy for multi-step dependencies in caches, and
>> - fixing issues that allow us to use these 3 as caches again.
>>
>> 1. Downgrade debug_args_for_decl to non-cache
>> 2. Add struct tree_decl_map_hasher
>> 3. Downgrade debug_expr_for_decl to non-cache
>> 4. Downgrade value_expr_for_decl to non-cache
>> 5. Don't mark live recursively in gt_cleare_cache
>>
>> Bootstrapped and reg-tested on x86_64, with ENABLE_CHECKING.
>>
>> I'll post the patches in response to this email.
>>
>
> This patch:
> - disables the recursive marking of cache entries during the cache-clear
>   phase
> - Adds ENABLE_CHECKING code to check that we don't end up with partially
>   dead cache entries
>
> OK for trunk?

It seems your docs do not match the implementation with regarding to
keep_cache_entry returning -1.  It looks like -1 is a "I do not know" value
which IMHO is bad to have.

I miss documentation of the ggc_marked_nonkey_p function and what it
is supposed to return.  As the function seems to be manually implemented
it also looks error-prone - I suppose gengtype could generate those.

+#ifdef ENABLE_CHECKING
+           gcc_assert (!ggc_marked_p (*iter));
+#endif

gcc_checking_assert ()

+#ifdef ENABLE_CHECKING
+           gcc_assert (H::ggc_marked_nonkey_p (*iter));
+#endif

likewise.

Rather than conditionalizing build of the ggc_marked_nonkey_p
functions can you mark them UNUSED (I suppose you only
avoid defined-but-not-used Werror errors)?  We try to get away
from conditional compilation.

Thanks,
Richard.

> Thanks,
> - Tom
>

Reply via email to