Skip to content

Commit 498c649

Browse files
gh-94841: Ensure arena_map_get() is inlined in PyObject_Free() (GH-94842)
(cherry picked from commit 9b3f779) Co-authored-by: neonene <[email protected]>
1 parent 91f7914 commit 498c649

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix the possible performance regression of :c:func:`PyObject_Free` compiled with MSVC version 1932.

Objects/obmalloc.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1445,7 +1445,7 @@ static arena_map_bot_t arena_map_root;
14451445

14461446
/* Return a pointer to a bottom tree node, return NULL if it doesn't exist or
14471447
* it cannot be created */
1448-
static arena_map_bot_t *
1448+
static Py_ALWAYS_INLINE arena_map_bot_t *
14491449
arena_map_get(block *p, int create)
14501450
{
14511451
#ifdef USE_INTERIOR_NODES

0 commit comments

Comments
 (0)