ablaha

parent af4199c7
......@@ -465,6 +465,12 @@ inline int gp_at_newframe(SCM *pt)
#define GC_MARK(x) (mark_stack_ptr = GC_MARK_AND_PUSH (SCM2PTR (x), mark_stack_ptr, mark_stack_limit, NULL))
#define GC_MARK_NT(x) (mark_stack_ptr = GC_MARK_AND_PUSH_NO_TOUCH (SCM2PTR (x), mark_stack_ptr, mark_stack_limit, NULL))
void gp_sweep_handle(SCM in);
struct GC_ms_entry *gp_stack_mark(SCM pt,
struct GC_ms_entry *ptr,
struct GC_ms_entry *limit);
void gp_clear_marks(SCM in, int isBefore);
#include "gc.c"
static struct GC_ms_entry *
gp_stack_mark0(SCM obj, int unlocked,
struct GC_ms_entry *mark_stack_ptr,
......@@ -473,7 +479,7 @@ gp_stack_mark0(SCM obj, int unlocked,
struct gp_stack *gp = GET_GP(obj);
int i;
//printf("mark\n");
//printf("mark %d\n", gp_gc_p);
GC_MARK(GP_UNREF((SCM *) gp));
GC_MARK(gp->dynstack);
......@@ -793,6 +799,7 @@ void gp_clear_marks(SCM in, int isBefore)
//printf("end clear\n");
}
void gp_sweep_handle(SCM in)
{
struct gp_stack *gp = GET_GP(in);
......@@ -801,7 +808,7 @@ void gp_sweep_handle(SCM in)
SCM *pt;
// printf("sweep\n");
// printf("sweep %d\n",gp_gc_p);
// Search for the first newframe stored
for(pt = gp->gp_ci - 1; pt >= gp->gp_cstack + 4; pt--)
......@@ -946,7 +953,6 @@ void gp_sweep_handle(SCM in)
//printf("end sweep\n");
}
#include "gc.c"
struct GC_ms_entry *gp_stack_mark(SCM pt,
struct GC_ms_entry *ptr,
......
......@@ -1381,17 +1381,20 @@ static SCM gp_unify(SCM *id1, SCM *id2, int raw, int gp_plus_unify, SCM *l, stru
SCM s = gp_make_s(ci,l);
SCM l = id1[1];
while(SCM_CONSP(l))
SCM xl = id1[1];
while(SCM_CONSP(xl))
{
s =
scm_call_5(SCM_CAAR(l), SCM_CDAR(l),*id2, scmraw, scm_plus, s);
l = SCM_CDR(l);
}
scm_call_5(SCM_CAAR(xl), SCM_CDAR(xl),*id2, scm_raw,
scm_plus, s);
if(scm_is_false(s))
return (SCM) 0;
xl = SCM_CDR(xl);
}
{
SCM ll = SCM_CDR(s);
if(vlist_p(ll))
......
......@@ -1429,6 +1429,7 @@
(+o m k n))
(<define> (*o n m p)
(<code> (gc))
(<condi>
((<=> '() n) (<=> '() p))
((poso n) (<=> '() m) (<=> '() p))
......
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