Skip to content

Reference counting stats do not account for immortal objects. #124284

Closed
@markshannon

Description

@markshannon

Bug description:

The reference counting stats (for example) show stats for increfs and decrefs (both in the interpreter and in the rest of the executable).

One might assume that is the number of Py_INCREF and Py_DECREFs executed, but it is not. It is the number of Py_INCREF and Py_DECREF where the object in question is mortal. We should add stats for Py_INCREF and Py_DECREFs of immortal objects as well.

CPython versions tested on:

CPython main branch

Operating systems tested on:

No response

Linked PRs

Metadata

Metadata

Assignees

Labels

pendingThe issue will be closed if no feedback is provided

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions