GC is very expensive: am I doing something wrong?

Paul Rubin no.email at nospam.invalid
Tue Mar 23 05:57:56 EDT 2010


Stefan Behnel <stefan_ml at behnel.de> writes:
> While this is theoretically true, and it's good to be aware of this
> possibility, common string hash functions make it so rare in practice
> that a hash table will almost always outperform a trie for exact
> lookups. If it happens, it will either show up clearly enough in
> benchmarks or not be worth bothering.

It is unlikely to happen by accident.  You might care that it can
happen on purpose.  See: http://www.cs.rice.edu/~scrosby/hash/
that I cited in another post.  The article shows some sample attacks
on Python cgi's.




More information about the Python-list mailing list