void gc_activate_finref_threads(GC *gc) { Finref_Metadata* metadata = gc->finref_metadata; if(metadata->pending_finalizers || metadata->pending_weakrefs){ metadata->pending_finalizers = FALSE; metadata->pending_weakrefs = FALSE; vm_hint_finalize(); } }
void select_force_gc() { vm_gc_lock_enum(); if (gc_algorithm < 10) { force_gc(); } else if ((gc_algorithm / 10) == 2) { full_gc(0); } else if ((gc_algorithm / 10) == 3) { heap.old_objects.prev_pos = heap.old_objects.pos; copy_gc(0); } vm_gc_unlock_enum(); hythread_suspend_disable(); vm_hint_finalize(); hythread_suspend_enable(); }