[New-bugs-announce] [issue1943] improved allocation of PyUnicode objects
report at bugs.python.org
Sat Jan 26 23:44:35 CET 2008
New submission from Antoine Pitrou:
This is an attempt at improving allocation of str (PyUnicode) objects.
For that it does two things:
1. make str objects PyVarObjects, so that the object is allocated in one
pass rather than two
2. maintain an array of freelists, each for a given str length, so that
many str allocations can bypass actual memory allocation calls
There is a ~10% speedup in stringbench, and a slight improvement in
pybench (as invoked with "./python Tools/pybench/pybench.py -t String").
Also, memory consumption is a bit lower when running those benchmarks.
components: Interpreter Core
title: improved allocation of PyUnicode objects
versions: Python 3.0
Added file: http://bugs.python.org/file9296/unialloc.patch
Tracker <report at bugs.python.org>
More information about the New-bugs-announce