]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-91247: Use memcpy for list and tuple repeat (#91482)
authorPieter Eendebak <pieter.eendebak@gmail.com>
Tue, 26 Jul 2022 02:10:23 +0000 (04:10 +0200)
committerGitHub <noreply@github.com>
Tue, 26 Jul 2022 02:10:23 +0000 (22:10 -0400)
commit2ef73be891eb95064e268341e38e81d008add480
tree895e2343dbbfc3c155d08301cf540deebd1bb259
parent27055d766ab0ee5ddcfbd1fb51fb47419af1ddba
gh-91247: Use memcpy for list and tuple repeat (#91482)

* Add _Py_memory_repeat function to pycore_list

* Add _Py_RefcntAdd function to pycore_object

* Use the new functions in tuplerepeat, list_repeat, and list_inplace_repeat
Include/internal/pycore_list.h
Include/internal/pycore_object.h
Misc/NEWS.d/next/Core and Builtins/2022-03-22-13-12-27.bpo-47091.tJcy-P.rst [new file with mode: 0644]
Objects/listobject.c
Objects/tupleobject.c