also experimented with less complex, no val-fn version, and this
was a little faster, but used as much memory. did not commit that
experiment to git.