Skip to content

Commit

Permalink
Skip dirty children in calculation of youngest generation
Browse files Browse the repository at this point in the history
  • Loading branch information
bacek committed Feb 3, 2011
1 parent c3fdc64 commit 676bbac
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/gc/gc_gms.c
Expand Up @@ -2152,6 +2152,10 @@ gc_gms_get_youngest_generation(PARROT_INTERP, ARGIN(PMC *pmc))
MarkSweep_GC *self = (MarkSweep_GC *)interp->gc_sys->gc_private;
size_t gen = POBJ2GEN(pmc);

/* If child is on dirty_list ignore it. It will be kept alive anyway */
if (pmc->flags & PObj_GC_on_dirty_list_FLAG)
return;

if (gen < self->youngest_child)
self->youngest_child = gen;
}
Expand Down

0 comments on commit 676bbac

Please sign in to comment.