-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Disable TSan in coroutine functions #22222
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
Disable TSan in coroutine functions #22222
Conversation
@swift-ci Please 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.
Looks good to me, although I think one of the comments is confusing.
lib/IRGen/IRGenSIL.cpp
Outdated
// Do not report races in deinit and anything called from it | ||
// because TSan does not observe synchronization between retain | ||
// count dropping to '0' and the object deinitialization. | ||
// Also don't report races in coroutines because the instrumentation |
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 think this comment "Also don't report races in coroutines..." is misplaced since we're not using "sanitize_thread_no_checking_at_run_time" for coroutines. Can we just remove the 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.
Yes, sorry, that was a legacy of a previous version of this commit in which the cases were merged.
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 will upload a new version of the patch after this one (presumably) passes the full test suite.
Thanks! |
Fixes rdar://47491307. I've filed rdar://47642395 to track re-enabling TSan in coroutines.
eec8466
to
0ca3f79
Compare
@swift-ci Please smoke test. |
Passed full test suite, re-running smoke tests with comment change. |
Fixes rdar://47491307.
I've filed rdar://47642395 to track re-enabling TSan in coroutines.