On Tue 08 Sep 2009 15:17, l...@gnu.org (Ludovic Courtès) writes: > We should implement constant folding in the tree-il->glil pass. A naive > implementation looks like this: > > diff --git a/module/language/tree-il/compile-glil.scm > b/module/language/tree-il/compile-glil.scm > index 86b610f..57a46c8 100644 > --- a/module/language/tree-il/compile-glil.scm > +++ b/module/language/tree-il/compile-glil.scm
Do it as a tree-il -> tree-il pass, as part of (language tree-il optimize), and you'll be happer. It will be easier to unit test, too. I think we should simply implement Waddell's algorithm. Andy -- http://wingolog.org/