diff options
author | Mark Shannon <mark@hotpy.org> | 2022-05-03 22:40:24 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-03 22:40:24 (GMT) |
commit | 836b17c9c3ea313e400e58a75f52b63f96e498bb (patch) | |
tree | 8b1a1c9e2466fa72ceee01558e76989b35c8bd56 /Objects/tupleobject.c | |
parent | e8d7661ff25fb698062ab07e37362c2c20471984 (diff) | |
download | cpython-836b17c9c3ea313e400e58a75f52b63f96e498bb.zip cpython-836b17c9c3ea313e400e58a75f52b63f96e498bb.tar.gz cpython-836b17c9c3ea313e400e58a75f52b63f96e498bb.tar.bz2 |
Add more stats for freelist use and allocations. (GH-92211)
Diffstat (limited to 'Objects/tupleobject.c')
-rw-r--r-- | Objects/tupleobject.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Objects/tupleobject.c b/Objects/tupleobject.c index f21d4da..dfb8597 100644 --- a/Objects/tupleobject.c +++ b/Objects/tupleobject.c @@ -1195,6 +1195,7 @@ maybe_freelist_pop(Py_ssize_t size) #endif _Py_NewReference((PyObject *)op); /* END inlined _PyObject_InitVar() */ + OBJECT_STAT_INC(from_freelist); return op; } } @@ -1224,6 +1225,7 @@ maybe_freelist_push(PyTupleObject *op) op->ob_item[0] = (PyObject *) STATE.free_list[index]; STATE.free_list[index] = op; STATE.numfree[index]++; + OBJECT_STAT_INC(to_freelist); return 1; } #endif |