diff options
author | Andy Wingo <wingo@pobox.com> | 2009-02-05 00:20:51 +0100 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2009-02-05 00:20:51 +0100 |
commit | 7edf2001274262ec7362c1dc96480aff8e176585 (patch) | |
tree | c3597bfe3644c61d35753bb5958cc9b03546c3ea /libguile/vm-engine.h | |
parent | 6d14383e866f447a0d2656fd319ba68a5737202c (diff) | |
download | guile-7edf2001274262ec7362c1dc96480aff8e176585.tar.gz |
inline call to scm_make_program when making closures
* libguile/programs.c (scm_make_program): Add a comment.
* libguile/vm-engine.h (INIT_ARGS): Add a couple of UNLIKELY notes.
* libguile/vm-i-system.c (make-closure): Inline the call to
scm_make_program, which avoids some redundant checks.
Diffstat (limited to 'libguile/vm-engine.h')
-rw-r--r-- | libguile/vm-engine.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libguile/vm-engine.h b/libguile/vm-engine.h index e14d8eba6..8fc3c136d 100644 --- a/libguile/vm-engine.h +++ b/libguile/vm-engine.h @@ -363,7 +363,7 @@ do { \ #define INIT_ARGS() \ { \ - if (bp->nrest) \ + if (SCM_UNLIKELY (bp->nrest)) \ { \ int n = nargs - (bp->nargs - 1); \ if (n < 0) \ @@ -374,7 +374,7 @@ do { \ } \ else \ { \ - if (nargs != bp->nargs) \ + if (SCM_UNLIKELY (nargs != bp->nargs)) \ goto vm_error_wrong_num_args; \ } \ } |