* mark.c (GC_push_selected): In case of a danger of mark stack overflow
after the first GC_push_all() call then call GC_push_all(bottom, top)
and return; remove redundant checking of GC_mark_stack_top at the end
of the function (overflow is already checked in GC_push_all).
return;
}
if ((*dirty_fn)(h-1)) {
+ if ((word)(GC_mark_stack_top - GC_mark_stack)
+ > 3 * GC_mark_stack_size / 4) {
+ GC_push_all(bottom, top);
+ return;
+ }
GC_push_all(bottom, h);
}
if ((ptr_t)h != top && (*dirty_fn)(h)) {
GC_push_all(h, top);
}
- if ((word)GC_mark_stack_top >= (word)GC_mark_stack_limit) {
- ABORT("Unexpected mark stack overflow");
- }
}
GC_API void GC_CALL GC_push_conditional(void *bottom, void *top, int all)