[Python-ideas] Ordered storage of keyword arguments

Antoine Pitrou solipsis at pitrou.net
Thu Oct 28 13:10:54 CEST 2010

On Thu, 28 Oct 2010 11:19:36 +0200
spir <denis.spir at gmail.com> wrote:
> On Thu, 28 Oct 2010 10:13:09 +0200
> "M.-A. Lemburg" <mal at egenix.com> wrote:
> > Ordered dicts are a lot slower than normal dictionaries. I don't
> > think that we can make such a change unless we want to make
> > Python a lot slower at the same time.
> Ruby has ordered hashes since 1.9 with apparently no relevant
> performance loss

Performance would probably not suffer on micro-benchmarks (with
everything fitting in the CPU's L1 cache), but making dicts bigger
(by 66%: 5 pointer-sized fields per hash entry instead of 3) could
be detrimental in real life workloads.



More information about the Python-ideas mailing list