Skip to content

Commit

Permalink
Add multi-heap support to gc_marks_wb_unprotected_objects
Browse files Browse the repository at this point in the history
  • Loading branch information
peterzhu2118 committed Jun 8, 2021
1 parent 8c87efa commit 892fa03
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gc.c
Original file line number Diff line number Diff line change
Expand Up @@ -7877,11 +7877,11 @@ gc_marks_wb_unprotected_objects_in_plane(rb_objspace_t *objspace, intptr_t p, bi
}

static void
gc_marks_wb_unprotected_objects(rb_objspace_t *objspace)
gc_marks_wb_unprotected_objects(rb_objspace_t *objspace, rb_heap_t *heap)
{
struct heap_page *page = 0;

list_for_each(&heap_eden->pages, page, page_node) {
list_for_each(&heap->pages, page, page_node) {
bits_t *mark_bits = page->mark_bits;
bits_t *wbun_bits = page->wb_unprotected_bits;
RVALUE *p = page->start;
Expand Down Expand Up @@ -7950,7 +7950,7 @@ gc_marks_finish(rb_objspace_t *objspace)

objspace->flags.during_incremental_marking = FALSE;
/* check children of all marked wb-unprotected objects */
gc_marks_wb_unprotected_objects(objspace);
gc_marks_wb_unprotected_objects(objspace, heap_eden);
}
#endif /* GC_ENABLE_INCREMENTAL_MARK */

Expand Down

0 comments on commit 892fa03

Please sign in to comment.