[Guile-commits] Failed: Hydra job gnu:guile-master:coverage on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:coverage (on x86_64-linux) has changed 
from Failed with output to Failed.  For details, see

  http://hydra.nixos.org/build/6613941


This is likely due to Arvin Moezzi moez...@gmail.com.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] GNU Guile branch, master, updated. v2.1.0-272-gcfc28c8

2013-10-25 Thread Andy Wingo
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project GNU Guile.

http://git.savannah.gnu.org/cgit/guile.git/commit/?id=cfc28c808e44582e9751b54713c58fd91ab53f16

The branch, master has been updated
   via  cfc28c808e44582e9751b54713c58fd91ab53f16 (commit)
  from  33e9a90d7b66d174c41b2cf0c8c89d4a3fa88443 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -
commit cfc28c808e44582e9751b54713c58fd91ab53f16
Author: Andy Wingo wi...@pobox.com
Date:   Fri Oct 25 12:25:53 2013 +0200

Evaluator uses two-dimensional environment

* libguile/memoize.c (MAKMEMO_LEX_REF, MAKMEMO_LEX_SET): Change to
  address lexicals by depth and width.
  (try_lookup_rib, lookup_rib, make_pos): New helpers.
  (lookup): Adapt to return a pair.
  (memoize, unmemoize_bindings, unmemoize_lexical): Adapt.

* libguile/eval.c (eval, prepare_boot_closure_env_for_eval):
  (prepare_boot_closure_env_for_apply):
* module/ice-9/eval.scm (make-fixed-closure, make-general-closure)
  (eval): Adapt to new environment.

This is currently a slight win for C, and a slight lose for Scheme --
because the lookup loop is so poorly compiled by the stack VM.  I expect
that the RTL-compiled eval will fix this.

---

Summary of changes:
 libguile/eval.c   |  236 ++-
 libguile/memoize.c|  194 ++--
 module/ice-9/eval.scm |  331 ++--
 3 files changed, 424 insertions(+), 337 deletions(-)

diff --git a/libguile/eval.c b/libguile/eval.c
index 205de2d..36199a6 100644
--- a/libguile/eval.c
+++ b/libguile/eval.c
@@ -153,6 +153,48 @@ static void prepare_boot_closure_env_for_eval (SCM proc, 
unsigned int argc,
 #define CADDR(x) SCM_CADDR(x)
 #define CDDDR(x) SCM_CDDDR(x)
 
+#define VECTOR_REF(v, i) (SCM_SIMPLE_VECTOR_REF (v, i))
+#define VECTOR_SET(v, i, x) (SCM_SIMPLE_VECTOR_SET (v, i, x))
+#define VECTOR_LENGTH(v) (SCM_SIMPLE_VECTOR_LENGTH (v))
+
+static SCM
+make_env (int n, SCM init, SCM next)
+{
+  SCM env = scm_c_make_vector (n + 1, init);
+  VECTOR_SET (env, 0, next);
+  return env;
+}
+
+static SCM
+next_rib (SCM env)
+{
+  return VECTOR_REF (env, 0);
+}
+
+static SCM
+env_tail (SCM env)
+{
+  while (SCM_I_IS_VECTOR (env))
+env = next_rib (env);
+  return env;
+}
+
+static SCM
+env_ref (SCM env, int depth, int width)
+{
+  while (depth--)
+env = next_rib (env);
+  return VECTOR_REF (env, width + 1);
+}
+
+static void
+env_set (SCM env, int depth, int width, SCM val)
+{
+  while (depth--)
+env = next_rib (env);
+  VECTOR_SET (env, width + 1, val);
+}
+
 
 SCM_SYMBOL (scm_unbound_variable_key, unbound-variable);
 
@@ -245,10 +287,13 @@ eval (SCM x, SCM env)
 case SCM_M_LET:
   {
 SCM inits = CAR (mx);
-SCM new_env = CAPTURE_ENV (env);
-for (; scm_is_pair (inits); inits = CDR (inits))
-  new_env = scm_cons (EVAL1 (CAR (inits), env),
-  new_env);
+SCM new_env;
+int i;
+
+new_env = make_env (VECTOR_LENGTH (inits), SCM_UNDEFINED,
+CAPTURE_ENV (env));
+for (i = 0; i  VECTOR_LENGTH (inits); i++)
+  env_set (new_env, 0, i, EVAL1 (VECTOR_REF (inits, i), env));
 env = new_env;
 x = CDR (mx);
 goto loop;
@@ -325,11 +370,15 @@ eval (SCM x, SCM env)
 
 case SCM_M_LEXICAL_REF:
   {
-int n;
-SCM ret;
-for (n = SCM_I_INUM (mx); n; n--)
-  env = CDR (env);
-ret = CAR (env);
+SCM pos, ret;
+int depth, width;
+
+pos = mx;
+depth = SCM_I_INUM (CAR (pos));
+width = SCM_I_INUM (CDR (pos));
+
+ret = env_ref (env, depth, width);
+
 if (SCM_UNLIKELY (SCM_UNBNDP (ret)))
   /* we don't know what variable, though, because we don't have its
  name */
@@ -339,11 +388,16 @@ eval (SCM x, SCM env)
 
 case SCM_M_LEXICAL_SET:
   {
-int n;
+SCM pos;
+int depth, width;
 SCM val = EVAL1 (CDR (mx), env);
-for (n = SCM_I_INUM (CAR (mx)); n; n--)
-  env = CDR (env);
-SCM_SETCAR (env, val);
+
+pos = CAR (mx);
+depth = SCM_I_INUM (CAR (pos));
+width = SCM_I_INUM (CDR (pos));
+
+env_set (env, depth, width, val);
+
 return SCM_UNSPECIFIED;
   }
 
@@ -352,8 +406,7 @@ eval (SCM x, SCM env)
 return SCM_VARIABLE_REF (mx);
   else
 {
-  while (scm_is_pair (env))
-env = CDR (env);
+  env = env_tail (env);
   return SCM_VARIABLE_REF
 

[Guile-commits] Failed: Hydra job gnu:guile-master:build_without_threads on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_without_threads (on 
x86_64-linux) has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615792


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_disable_deprecated_disable_discouraged on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job 
gnu:guile-master:build_disable_deprecated_disable_discouraged (on x86_64-linux) 
has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615771


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build (on x86_64-linux) has changed 
from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615774


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_disable_networking on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_disable_networking (on 
x86_64-linux) has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615770


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_enable_guile_debug on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_enable_guile_debug (on 
x86_64-linux) has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615772


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_CPPFLAGS=_DSCM_DEBUG_TYPING_STRICTNESS=2 on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job 
gnu:guile-master:build_CPPFLAGS=_DSCM_DEBUG_TYPING_STRICTNESS=2 (on 
x86_64-linux) has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615767


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_CPPFLAGS=_DSCM_DEBUG=1 on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_CPPFLAGS=_DSCM_DEBUG=1 (on 
x86_64-linux) has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615780


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_gcc47 on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_gcc47 (on x86_64-linux) has 
changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615786


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_without_threads on i686-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_without_threads (on i686-linux) 
has changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615762


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build on i686-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build (on i686-linux) has changed from 
Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615761


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_clang on x86_64-linux

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_clang (on x86_64-linux) has 
changed from Success to Failed.  For details, see

  http://hydra.nixos.org/build/6615789


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.



[Guile-commits] Failed: Hydra job gnu:guile-master:build_without_threads on x86_64-darwin

2013-10-25 Thread Hydra Build Daemon
Hi,

The status of Hydra job gnu:guile-master:build_without_threads (on 
x86_64-darwin) has changed from Failed with output to Failed.  For details, 
see

  http://hydra.nixos.org/build/6615765


This is likely due to 32 commits by Andy Wingo wi...@pobox.com, Arvin Moezzi 
moez...@gmail.com, Carles Pagès p...@cubata.homelinux.net, Eelco Dolstra 
eelco.dols...@logicblox.com, Evgeny Egorochkin phree...@yandex.ru, Jaka 
Hudoklin jakahudok...@gmail.com or Peter Simons sim...@cryp.to.

Go forth and fix it.

Regards,

The Hydra build daemon.