Skip to content

Commit 9b3f779

Browse files
authored
gh-94841: Ensure arena_map_get() is inlined in PyObject_Free() (#94842)
1 parent 6cbb57f commit 9b3f779

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
@@ -1446,7 +1446,7 @@ static arena_map_bot_t arena_map_root;
14461446

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

0 commit comments

Comments
 (0)