summaryrefslogtreecommitdiff
path: root/src/lisp/ao_lisp_lambda.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2016-11-14 18:45:12 -0800
committerKeith Packard <keithp@keithp.com>2016-11-17 22:18:39 -0800
commit72e16314541a25257dd1cf072b732ded2911e00f (patch)
tree3e0420e08042f6352f221e7b48520e23433c601a /src/lisp/ao_lisp_lambda.c
parentb41d0f3c5337faa4337d9686c45815e900d86bf5 (diff)
altos/lisp: Change GC to do moves in batches of 32
This should make it quite a bit faster than doing one at a time. Signed-off-by: Keith Packard <keithp@keithp.com>
Diffstat (limited to 'src/lisp/ao_lisp_lambda.c')
-rw-r--r--src/lisp/ao_lisp_lambda.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lisp/ao_lisp_lambda.c b/src/lisp/ao_lisp_lambda.c
index c53a38fd..6020a8b8 100644
--- a/src/lisp/ao_lisp_lambda.c
+++ b/src/lisp/ao_lisp_lambda.c
@@ -47,6 +47,7 @@ const struct ao_lisp_type ao_lisp_lambda_type = {
.size = lambda_size,
.mark = lambda_mark,
.move = lambda_move,
+ .name = "lambda",
};
void
@@ -68,7 +69,9 @@ ao_lisp_lambda_print(ao_poly poly)
ao_poly
ao_lisp_lambda_alloc(struct ao_lisp_cons *code, int args)
{
+ ao_lisp_cons_stash(0, code);
struct ao_lisp_lambda *lambda = ao_lisp_alloc(sizeof (struct ao_lisp_lambda));
+ code = ao_lisp_cons_fetch(0);
struct ao_lisp_cons *arg;
int f;