[issue47009] Streamline list.append for the common case

2022-04-05 Thread Dennis Sweeney
Dennis Sweeney added the comment: Buildbots are passing, so I'm closing this. Thanks for the catch and fix! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue47009] Streamline list.append for the common case

2022-04-05 Thread Christian Heimes
Christian Heimes added the comment: New changeset 9e88b572fb904b172f9e344069fb7118f1cee517 by Christian Heimes in branch 'main': bpo-47009: Fix assert on big endian (GH-32332) https://github.com/python/cpython/commit/9e88b572fb904b172f9e344069fb7118f1cee517 -- _

[issue47009] Streamline list.append for the common case

2022-04-05 Thread Christian Heimes
Change by Christian Heimes : -- nosy: +christian.heimes nosy_count: 3.0 -> 4.0 pull_requests: +30389 pull_request: https://github.com/python/cpython/pull/32332 ___ Python tracker _

[issue47009] Streamline list.append for the common case

2022-04-05 Thread Mark Shannon
Mark Shannon added the comment: New changeset 6c6e0408a663c1f53dad403f54a18d444da39cb7 by Dennis Sweeney in branch 'main': bpo-47009: Let PRECALL_NO_KW_LIST_APPEND do its own POP_TOP (GH-32239) https://github.com/python/cpython/commit/6c6e0408a663c1f53dad403f54a18d444da39cb7 -- ___

[issue47009] Streamline list.append for the common case

2022-04-01 Thread Dennis Sweeney
Change by Dennis Sweeney : -- pull_requests: +30310 pull_request: https://github.com/python/cpython/pull/32239 ___ Python tracker ___ __

[issue47009] Streamline list.append for the common case

2022-04-01 Thread Mark Shannon
Mark Shannon added the comment: New changeset a0ea7a116ce52a178c02d42b684089758bd7f355 by Dennis Sweeney in branch 'main': bpo-47009: Streamline list.append for the common case (GH-31864) https://github.com/python/cpython/commit/a0ea7a116ce52a178c02d42b684089758bd7f355 -- nosy: +Mar

[issue47009] Streamline list.append for the common case

2022-03-15 Thread Inada Naoki
Inada Naoki added the comment: Thank you. I agree that inlining is worth enough. But we already inlined too many functions in ceval and there is an issue caused by it... (bpo-45116) -- ___ Python tracker _

[issue47009] Streamline list.append for the common case

2022-03-14 Thread Dennis Sweeney
Dennis Sweeney added the comment: The attached _PyList_AppendTakeRef.diff has the ceval.c, but this implementation: int _PyList_AppendTakeRef(PyListObject *self, PyObject *newitem) { assert(self != NULL && newitem != NULL); assert(PyList_Check(self)); Py_ssize_t len = PyList_GET_S

[issue47009] Streamline list.append for the common case

2022-03-14 Thread Inada Naoki
Inada Naoki added the comment: Hmm. Would you measure benefit from inlining and skipping incref/decref separately? If benefit of inlining is very small, making _PyList_AppendTakeRef() as regular internal API looks better to me. -- nosy: +methane

[issue47009] Streamline list.append for the common case

2022-03-13 Thread Dennis Sweeney
Change by Dennis Sweeney : -- keywords: +patch pull_requests: +29962 stage: -> patch review pull_request: https://github.com/python/cpython/pull/31864 ___ Python tracker ___ _

[issue47009] Streamline list.append for the common case

2022-03-13 Thread Dennis Sweeney
New submission from Dennis Sweeney : list_resize is a long function that probably won't get inlined. But for the vast majority of cases in list.append, we just need to check whether the list is big enough (not whether it's small enough, or whether it's null or the wrong type), then insert and