Skip to content

threading.local() access should scale well from multiple threads #128691

Closed
@colesbury

Description

@colesbury

Currently, accessing a threading.local() from multiple threads doesn't scale well because of reference count contention on the shared _thread._local object. We should use deferred reference counting on _thread._local to avoid this bottleneck.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions