remove duplicated incremental_gc_until() in generational GC; #1449

parent 93d2cb02
...@@ -1007,16 +1007,15 @@ mrb_full_gc(mrb_state *mrb) ...@@ -1007,16 +1007,15 @@ mrb_full_gc(mrb_state *mrb)
GC_INVOKE_TIME_REPORT("mrb_full_gc()"); GC_INVOKE_TIME_REPORT("mrb_full_gc()");
GC_TIME_START; GC_TIME_START;
if (mrb->gc_state != GC_STATE_NONE) {
/* finish half baked GC cycle */
incremental_gc_until(mrb, GC_STATE_NONE);
}
/* clear all the old objects back to young */
if (is_generational(mrb)) { if (is_generational(mrb)) {
/* clear all the old objects back to young */
clear_all_old(mrb); clear_all_old(mrb);
mrb->gc_full = TRUE; mrb->gc_full = TRUE;
} }
else if (mrb->gc_state != GC_STATE_NONE) {
/* finish half baked GC cycle */
incremental_gc_until(mrb, GC_STATE_NONE);
}
incremental_gc_until(mrb, GC_STATE_NONE); incremental_gc_until(mrb, GC_STATE_NONE);
mrb->gc_threshold = (mrb->gc_live_after_mark/100) * mrb->gc_interval_ratio; mrb->gc_threshold = (mrb->gc_live_after_mark/100) * mrb->gc_interval_ratio;
......
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