[New-bugs-announce] [issue14435] Remove special block allocation from floatobject.c
Kristján Valur Jónsson
report at bugs.python.org
Thu Mar 29 11:54:09 CEST 2012
New submission from Kristján Valur Jónsson <kristjan at ccpgames.com>:
floatobject.c has its own block allocator. This appears to be ancient, from before the time when obmalloc.c was invented.
This patch removes this allocator and puts an upper limit on the freelist of floats. The purpose of this is to reduce memory fragmentation, since blocks used for floats cannot be used for anything else in python. These blocks tend to stay around for a long time, it is sufficient for one float from each of the 1k blocks to be alive to keep that block present in memory forever.
It is the presence of the fast freelist that is the performance enhancer here, not the fast block allocator.
components: Interpreter Core
title: Remove special block allocation from floatobject.c
versions: Python 3.3
Added file: http://bugs.python.org/file25061/nofreelist.patch
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce