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

notify_all_at_thread_exit seg faults if run from a raw pthread context. #29557

Closed
llvmbot opened this issue Aug 30, 2016 · 3 comments
Closed
Labels
bugzilla Issues migrated from bugzilla libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.

Comments

@llvmbot
Copy link
Collaborator

llvmbot commented Aug 30, 2016

Bugzilla Link 30202
Resolution FIXED
Resolved on Sep 03, 2016 03:08
Version unspecified
OS Linux
Reporter LLVM Bugzilla Contributor
CC @mclow

Extended Description

std::thread's ctor allocates a __thread_struct, and stuffs it in a thread local variable. std::notify_all_at_thread_exit tries to use that __thread_struct.

If a thread is created with pthread_create instead of std::thread, then the __thread_struct never gets allocated, and std::notify_all_at_thread_exit seg faults.

@llvmbot
Copy link
Collaborator Author

llvmbot commented Sep 1, 2016

Potential fix up for review as https://reviews.llvm.org/D24159.

1 similar comment
@llvmbot
Copy link
Collaborator Author

llvmbot commented Sep 2, 2016

Potential fix up for review as https://reviews.llvm.org/D24159.

@llvmbot
Copy link
Collaborator Author

llvmbot commented Sep 3, 2016

r280588.

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 10, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.
Projects
None yet
Development

No branches or pull requests

1 participant