Skip to content

Commit

Permalink
Merge pull request #13 from jacob-hughes/disclaim_mark_children
Browse files Browse the repository at this point in the history
Allow finalized_malloc to delay reclaiming disclaimed objects
  • Loading branch information
ltratt authored Apr 2, 2024
2 parents 10f5f84 + 4f2af10 commit 216d7de
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .buildbot_dockerfile_debian
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM debian:bullseye
FROM debian:latest
ARG CI_UID
RUN useradd -m -u ${CI_UID} ci
RUN apt-get update && \
Expand Down
7 changes: 7 additions & 0 deletions fnlz_mlc.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,14 @@ STATIC int GC_CALLBACK GC_finalized_disclaim(void *obj)
GC_ASSERT(!GC_find_leak);
(*fc->proc)((word *)obj + 1, fc->cd);
}
#ifdef DISCLAIM_MARK_CHILDREN
/* Prevent the objects reachable from the disclaimed object from */
/* being reclaimed immediately by marking them as live. Useful if */
/* the disclaim function queues objects to be finalised later. */
return 1;
#else
return 0;
#endif
}

STATIC void GC_register_disclaim_proc_inner(unsigned kind,
Expand Down

0 comments on commit 216d7de

Please sign in to comment.