-USING: tools.test tools.memory memory arrays ;
+USING: arrays math memory namespaces parser sequences tools.memory
+tools.memory.private tools.test tools.time ;
IN: tools.memory.tests
{ } [ room. ] unit-test
{ } [ gc-stats. ] unit-test
{ } [ gc-summary. ] unit-test
{ } [ callback-room. ] unit-test
+
+! Each gc-event must reclaim something. #659
+{ f } [
+ [ "resource:basis/tools/memory/memory.factor" run-file ] time
+ gc-events get [ space-reclaimed 0 < ] any?
+] unit-test
}
void factor_vm::start_gc_again() {
- end_gc();
-
switch (current_gc->op) {
case collect_nursery_op:
/* Nursery collection can fail if aging does not have enough
critical_error("in start_gc_again, bad GC op", current_gc->op);
break;
}
-
- if (gc_events)
- current_gc->event = new gc_event(current_gc->op, this);
}
void factor_vm::set_current_gc_op(gc_op op) {