Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 34k
gh-112536: Add --tsan test for reasonable TSAN execution times.#116601
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
Uh oh!
There was an error while loading. Please reload this page.
Conversation
corona10 commented Mar 11, 2024 • edited by github-actions bot
Loading Uh oh!
There was an error while loading. Please reload this page.
edited by github-actions bot
Uh oh!
There was an error while loading. Please reload this page.
| @@ -0,0 +1,3 @@ | |||
| ## reference: https://github.com/google/sanitizers/wiki/ThreadSanitizerSuppressions | |||
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 am going to update the list of supressions.txt when working on the CI things.
Uh oh!
There was an error while loading. Please reload this page.
Lib/test/libregrtest/tsan.py Outdated
| 'test_capi', | ||
| 'test_code', | ||
| 'test_compileall', | ||
| 'test_concurrent_futures', |
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.
==14799==ThreadSanitizer: starting new threads after multi-threaded fork is not supported. Dying (set die_after_fork=0 to override) Uh oh!
There was an error while loading. Please reload this page.
corona10 commented Mar 11, 2024
@colesbury
|
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Alex Waygood <[email protected]>
corona10 commented Mar 11, 2024
Anyway, we should exclude some of test from the list since it takes over 1 hours :) |
corona10 commented Mar 11, 2024 • edited
Loading Uh oh!
There was an error while loading. Please reload this page.
edited
Uh oh!
There was an error while loading. Please reload this page.
I think that this setting could be the minimum setup for adding TSAN in CI. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Lib/test/libregrtest/cmdline.py Outdated
| group.add_argument('--pgo-extended', action='store_true', | ||
| help='enable extended PGO training (slower training)') | ||
| group.add_argument('--tsan', dest='tsan', action='store_true', | ||
| help='enable TSAN test') |
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.
Can you explain what "TSAN test" means here? From the rest of the diff it sounds like it's "Tests that pass in a reasonable amount of time with TSAN enabled", but that's not clear from this help string.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Lib/test/libregrtest/tsan.py Outdated
| 'test_importlib', | ||
| 'test_io', | ||
| 'test_logging', | ||
| 'test_tuple', |
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 don't think test_tuple uses threads. I don't think it's worthwhile to run tests that don't use threads, because we won't uncover anything new with TSAN.
corona10Mar 12, 2024 • edited
Loading Uh oh!
There was an error while loading. Please reload this page.
edited
Uh oh!
There was an error while loading. Please reload this page.
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 got it; I removed more tests that are not using the thread currently.
| group.add_argument('--pgo-extended', action='store_true', | ||
| help='enable extended PGO training (slower training)') | ||
| group.add_argument('--tsan', dest='tsan', action='store_true', | ||
| help='run a subset of test cases that are proper for the TSAN test') |
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.
@swtaarrs It will be the more clear?
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.
Sorry, I completely missed this notification. Looks good to me :)
colesbury left a comment
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.
This looks like a good start to me. We can build on it (edit the list of tests and suppressions) in the future.
… times. (pythongh-116601) (cherry picked from commit ebf29b3) Co-authored-by: Donghee Na <[email protected]>
GH-116929 is a backport of this pull request to the 3.12 branch. |
gh-116601) (#116929) (cherry picked from commit ebf29b3) Co-authored-by: Donghee Na <[email protected]>
--with-thread-sanitizer#112536📚 Documentation preview 📚: https://cpython-previews--116601.org.readthedocs.build/