[erlang-questions] scope of variables
Fri Sep 29 13:39:37 CEST 2006
On 9/25/06, Richard Carlsson <> wrote:
> Ok, it took a while before I had time to look at it, but the fact is
> that the normal inliner is technically able to do some of this stuff
> already - it's just not been enabled!
That's cool to know! However, if one needs something less simple than
just loop unrolling, then another approach is needed.
A few other applications of this "compile a customized variant of this
function given these static parameters" could be
* sparse vector multiplication, where all zero elements would just
eliminated from the calculation
* regexps, where it is possible (but I'm not sure if it applies to the
general case) to generate specializations of the generic algorithm
that are very close to hand-crafted variants.
More information about the erlang-questions