Skip to content

Data races in typeobject.c for type structure updates #133467

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
nascheme opened this issue May 5, 2025 · 0 comments
Open

Data races in typeobject.c for type structure updates #133467

nascheme opened this issue May 5, 2025 · 0 comments
Labels
interpreter-core (Objects, Python, Grammar, and Parser dirs) topic-free-threading type-bug An unexpected behavior, bug, or error

Comments

@nascheme
Copy link
Member

nascheme commented May 5, 2025

Bug report

Bug description:

There are some additional data races (producing TSAN warnings) for typeobject.c in the free-threaded build.

The following stores are unsafe:

  • _Py_slot_tp_getattr_hook re-assigns tp_getattro
  • slot_tp_descr_get assigns to tp_descr_get
  • type_set_name assigns to tp_name
  • tp_base and tp_bases are assigned in likely unsafe ways

CPython versions tested on:

CPython main branch

Operating systems tested on:

No response

Linked PRs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
interpreter-core (Objects, Python, Grammar, and Parser dirs) topic-free-threading type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

2 participants