summaryrefslogtreecommitdiffstats
path: root/Objects/cobject.c
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2004-03-14 06:42:23 (GMT)
committerRaymond Hettinger <python@rcn.com>2004-03-14 06:42:23 (GMT)
commit0e91643bd27132554546465d37bcc01573768aa6 (patch)
tree7837131aba76b97310b085572c7a90d0d0f82765 /Objects/cobject.c
parent49f9bd15ffeef67358a319f89faeaa31ad97d575 (diff)
downloadcpython-0e91643bd27132554546465d37bcc01573768aa6.zip
cpython-0e91643bd27132554546465d37bcc01573768aa6.tar.gz
cpython-0e91643bd27132554546465d37bcc01573768aa6.tar.bz2
list_resize() now has an "exact" option for bypassing the overallocation
scheme in situations that likely won't benefit from it. This further improves memory utilization from Py2.3 which always over-allocates except for PyList_New(). Situations expected to benefit from over-allocation: list.insert(), list.pop(), list.append(), and list.extend() Situations deemed unlikely to benefit: list_inplace_repeat, list_ass_slice, list_ass_subscript The most gray area was for listextend_internal() which only runs when the argument is a list or a tuple. This could be viewed as a one-time fixed length addition or it could be viewed as wrapping a series of appends. I left its over-allocation turned on but could be convinced otherwise.
Diffstat (limited to 'Objects/cobject.c')
0 files changed, 0 insertions, 0 deletions