Hello everyone.
Thanks raymond for writing down a pure python version ;-)
Thanks for running with it.
I did an initial port to RPython for experiments. The results (on
large dicts only) are inconclusive - it's either a bit faster or a bit
slower, depending what exactly you do. There is a possibility I messed
something up too (there is a branch rdict-experiments in PyPy, in a
very sorry state though).
One effect we did not think about is that besides extra indirection,
there is an issue with data locality - having to look in two different
large lists seems to be a hit.
In pure python, I didn't see a way to bring the hash/key/value entries
side-by-side as they currently are in CPython. How does PyPy currently
handle this issue? Is there a change I could make to the recipe that
would restore data locality?
Raymond