[issue23507] Tuple creation is too slow

Demur Rumed report at bugs.python.org
Sat Apr 23 08:11:11 EDT 2016


Demur Rumed added the comment:

This code could be made to look a lot less hackish if the potential tuple reuse was abstracted by a PyTuple_UniqueOrNew(PyTuple) which returns its argument if REFCNT==1 otherwise allocates a tuple of the same size & returns that. It decrefs PyTuple if REFCNT != 1

----------
nosy: +Demur Rumed

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue23507>
_______________________________________


More information about the Python-bugs-list mailing list