Skip to content

gh-112075: Remove critical section in dict.get #129336

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

Merged
merged 3 commits into from
Jan 28, 2025
Merged

Conversation

eendebakpt
Copy link
Contributor

@eendebakpt eendebakpt commented Jan 27, 2025

  • The dict.get implementation uses _Py_dict_lookup_threadsafe which is thread-safe, so we remove the critical section from the argument clinic.
  • Add a test for concurrent dict get and set operations

@colesbury colesbury enabled auto-merge (squash) January 28, 2025 21:33
@colesbury
Copy link
Contributor

Thanks!

@colesbury colesbury merged commit 64c417d into python:main Jan 28, 2025
40 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants