[issue27350] Compact and ordered dict
STINNER Victor
report at bugs.python.org
Sat Sep 10 03:05:47 EDT 2016
STINNER Victor added the comment:
As I expected, a dictionary lookup is a _little bit_ slower (3%) between Python 3.5 and Python 3.6:
$ ./python -m perf timeit -s 'd={str(i):i for i in range(100)}' 'd["10"]; d["20"]; d["30"]; d["40"]; d["50"]; d["10"]; d["20"]; d["30"]; d["40"]; d["50"]' --rigorous
Median +- std dev: [lookup35] 309 ns +- 10 ns -> [lookup36] 320 ns +- 8 ns: 1.03x slower
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue27350>
_______________________________________
More information about the Python-bugs-list
mailing list