Skip unnecessary `mark_context` if `mrb->c == mrb->root_c`.

parent 6334949b
......@@ -1076,7 +1076,9 @@ final_marking_phase(mrb_state *mrb, mrb_gc *gc)
}
mrb_gc_mark_gv(mrb);
mark_context(mrb, mrb->c);
if (mrb->c != mrb->root_c) {
mark_context(mrb, mrb->root_c);
}
mrb_gc_mark(mrb, (struct RBasic*)mrb->exc);
gc_mark_gray_list(mrb, gc);
mrb_assert(gc->gray_list == NULL);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment