- int i;
-
- memset(ao_lisp_busy, '\0', sizeof (ao_lisp_busy));
- memset(ao_lisp_cons, '\0', sizeof (ao_lisp_cons));
- ao_lisp_cons_noted = 0;
- DBG("mark\n");
- for (i = 0; i < AO_LISP_ROOT; i++) {
- if (ao_lisp_root[i].type) {
- void **a = ao_lisp_root[i].addr, *v;
- if (a && (v = *a)) {
- DBG("root %d\n", DBG_OFFSET(v));
- ao_lisp_mark(ao_lisp_root[i].type, v);
- }
- } else {
- ao_poly *a = (ao_poly *) ao_lisp_root[i].addr, p;
- if (a && (p = *a)) {
- DBG("root 0x%04x\n", p);
- ao_lisp_poly_mark(p, 0);
- }
- }
- }
- while (ao_lisp_cons_noted) {
- memcpy(ao_lisp_cons_last, ao_lisp_cons, sizeof (ao_lisp_cons));
- memset(ao_lisp_cons, '\0', sizeof (ao_lisp_cons));
- ao_lisp_cons_noted = 0;
- for (i = 0; i < AO_LISP_POOL; i += 4) {
- if (busy(ao_lisp_cons_last, i)) {
- void *v = ao_lisp_pool + i;
- DBG("cons %d\n", DBG_OFFSET(v));
- ao_lisp_mark(&ao_lisp_cons_type, v);
- }
- }
- }