-
-
Notifications
You must be signed in to change notification settings - Fork 30.7k
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
gh-117657: Add TSAN suppressions for the free-threaded build #117736
Merged
colesbury
merged 4 commits into
python:main
from
mpage:gh-117657-add-ft-tsan-suppressions
Apr 15, 2024
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# This file contains suppressions for the free-threaded build. It contains the | ||
# suppressions for the default build and additional suppressions needed only in | ||
# the free-threaded build. | ||
# | ||
# reference: https://github.com/google/sanitizers/wiki/ThreadSanitizerSuppressions | ||
|
||
## Default build suppresssions | ||
|
||
race:get_allocator_unlocked | ||
race:set_allocator_unlocked | ||
|
||
## Free-threaded suppressions | ||
|
||
race:_add_to_weak_set | ||
race:_in_weak_set | ||
race:_mi_heap_delayed_free_partial | ||
race:_Py_IsImmortal | ||
race:_Py_IsOwnedByCurrentThread | ||
race:_PyEval_EvalFrameDefault | ||
race:_PyFunction_SetVersion | ||
race:_PyImport_AcquireLock | ||
race:_PyImport_ReleaseLock | ||
race:_PyInterpreterState_SetNotRunningMain | ||
race:_PyInterpreterState_IsRunningMain | ||
race:_PyObject_GC_IS_SHARED | ||
race:_PyObject_GC_SET_SHARED | ||
race:_PyObject_GC_TRACK | ||
race:_PyType_HasFeature | ||
race:_PyType_Lookup | ||
race:assign_version_tag | ||
race:compare_unicode_unicode | ||
race:delitem_common | ||
race:dictkeys_decref | ||
race:dictkeys_incref | ||
race:dictresize | ||
race:gc_collect_main | ||
race:gc_restore_tid | ||
race:initialize_new_array | ||
race:insertdict | ||
race:lookup_tp_dict | ||
race:mi_heap_visit_pages | ||
race:PyMember_GetOne | ||
race:PyMember_SetOne | ||
race:new_reference | ||
race:set_contains_key | ||
race:set_inheritable | ||
race:start_the_world | ||
race:tstate_set_detached | ||
race:unicode_hash | ||
race:update_cache | ||
race:update_cache_gil_disabled |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
## reference: https://github.com/google/sanitizers/wiki/ThreadSanitizerSuppressions | ||
# This file contains suppressions for the default (with GIL) build. | ||
# reference: https://github.com/google/sanitizers/wiki/ThreadSanitizerSuppressions | ||
race:get_allocator_unlocked | ||
race:set_allocator_unlocked | ||
race:mi_heap_visit_pages | ||
race:_mi_heap_delayed_free_partial |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there GH issues open for all these suppressions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not yet, working on it :) I want to provide a bit more context (i.e. sample stacktraces + repro instructions) rather than just cutting issues without context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd like to start with a simple list in an omnibus issue like #117657 so that there's a single place that people can go look to track who is working on what races.
I expect many of the races to have simple fixes, but we can break off the more complex races into their own issues as needed.
The work of collecting stacktraces and repros is work that can be split up once this PR is landed and we have a way of coordinating the work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good. I threw together a quick script to massage the TSAN output from the tests into an index that we can use to look for stacktraces and tests that should reproduce the races.