Skip to content
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

Run TLS destructors for the main thread #88

Merged
merged 1 commit into from
Nov 20, 2022

Conversation

jamesbornholt
Copy link
Member

We weren't running the same TLS destructor logic for the main thread as
all other threads. This meant a thread-local on the main thread wouldn't
be dropped until the entire test finished, causing spurious deadlocks or
other confusion.

Fixes #86.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

We weren't running the same TLS destructor logic for the main thread as
all other threads. This meant a thread-local on the main thread wouldn't
be dropped until the entire test finished, causing spurious deadlocks or
other confusion.

Fixes awslabs#86.
@jorajeev jorajeev merged commit 9a69e91 into awslabs:main Nov 20, 2022
jorajeev pushed a commit that referenced this pull request Feb 29, 2024
We weren't running the same TLS destructor logic for the main thread as
all other threads. This meant a thread-local on the main thread wouldn't
be dropped until the entire test finished, causing spurious deadlocks or
other confusion.

Fixes #86.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

shuttle::thread_local isn't dropped when threads exit the scheduler
2 participants