Hacker News new | ask | show | jobs
by woadwarrior01 2045 days ago
Although cPython and Redis hashtables are both implemented in C. cPython's open addressing based hashtable[1] is far superior to the simple chaining based hashtable[2] in Redis. Python's performance is heavily dependent on the performance of its hash table implementation that it has been optimized over and over decades now.

[1]: https://github.com/python/cpython/blob/master/Objects/dictob...

[2]: https://github.com/redis/redis/blob/unstable/src/dict.c