[plt-dev] Fine-tuning performance

From: Carl Eastlund (cce at ccs.neu.edu)
Date: Fri Jan 29 12:27:33 EST 2010

I have some performance related questions about the PLT runtime.
These are mostly for Matthew, but I'm posting this to plt-dev in case
anyone else is interested in the answers, or can supply one.

One, there are some functions that I memoize with a weak hash table.
Are there any sorts of values that will never be collected, and will
persist forever in the hash table?  For instance, do word-sized values
like fixnums or ASCII characters stick around?

Two, I've gotten the impression that special casing variable-arity
functions at some fixed arities via case-lambda will speed up the
common case.  Is this true, and if so how significant is the
difference (as a general order of magnitude)?  Is there some cutoff
past which this specialization no longer pays off?  I know there's no
a priori precise answer, I'd have to experiment for that, but if
there's a representation change (e.g. functions calls with more than 8
arguments get allocated as lists regardless) it would be useful to
know.

Thanks for any help.

Carl Eastlund


Posted on the dev mailing list.