1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Fibers should update themselves on compaction

We should let fibers update their own references on compaction.  I don't
think we need the thread to update the associated fiber because there
will be a fiber object on the heap that knows how to update itself.
This commit is contained in:
Aaron Patterson 2020-09-25 09:18:12 -07:00 committed by Aaron Patterson
parent 8b42474a26
commit 137fa5b27e
Notes: git 2020-09-26 07:52:28 +09:00

7
vm.c
View file

@ -2658,11 +2658,10 @@ static void
thread_compact(void *ptr)
{
rb_thread_t *th = ptr;
rb_fiber_update_self(th->ec->fiber_ptr);
if (th->root_fiber) rb_fiber_update_self(th->root_fiber);
rb_execution_context_update(th->ec);
if (!th->root_fiber) {
rb_execution_context_update(th->ec);
}
}
static void