Commit Graph

4366 Commits

Author SHA1 Message Date
Vytautas Astrauskas
feb188360e Unify TLS dtors; move stepping outside. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
8240ed26a9 Change the test not to rely on internals. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
90e9a87fa7 Add an explanatory comment to the test. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
cc9248a7c8 Ignore prctl test on MacOS because it does not support it. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
eaa63266d8 Make multiple threads to try to join a thread while it is still running. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
d45e985669 Clarify FIXME. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
8a7dbde372 Check prctl argument types and fix the test. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
40e50bf58b Clarify test comments. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
e7b82fde4a Fix the test annotation. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
e7c2694b8b Make the main thread detached. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
69eaaadc28 Fix merge error. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
452e36efb3 Print the thread name in Debug. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
3bb1657448 Small style fix. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
9a01c3fa3e Clarify comments about TLS destructor handling in Windows, add a test for TLS destructors. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
e4dc3567f8 Track if a thread was already joined. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
5b55e0706c Add more concurrency tests. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
17f7bc86ae Fix how a pthread_create function argument is constructed. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
80459bbf77 Improve concurrency tests. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
94cbe88e80 Many small changes to thread management. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
75e6549c11 Improve prctl, add a test. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
eab38dfe00 Change the warning message. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
69df2e19de Move prctl to Linux specific shims. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
d6c03926ab Rename MacOS set global dtor function. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
c84b2890ad Update a comment in README about what concurrency checks we support. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
421be273cc Add concurrency tests. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
46fd333daa Implement thread::yield_now. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
134533d066 Add a comment explaining global destructors on MacOS. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
d062f63519 Fix support for MacOS. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
44e9305599 Rename threads to thread to match the Rust standard library. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
a585dc8289 Add a missing newline. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
688cacbdd7 Cleanup the implementation of adjust_global_const. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
1d0eb93ebd Fix typo in a comment. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
94118d4d9a Make an assert message consistent with other asserts. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
552080a5b7 Fix imports. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
d9ec0f2b36 Add a missing newline in the test. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
4609c3c520 Rename eval_maybe_thread_local_static_const to adjust_global_const. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
325c31e578 Address some of the reviewers comments. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
51b16e56cd Generate thread local allocations in eval_maybe_thread_local_static_const. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
963e9698f9 Generate fresh allocation ids for thread locals in eval_maybe_thread_local_static_const. 2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
0c4303cd7f Small refactoring in pthread sync: extract common functionallity to separate functions. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
d907fb5021 Rename ThreadSet to ThreadManager. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
1c8a59c691 Rebase on PR 1157. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
2202278f6a Fix pthread_self. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
b04bf8a514 Rustfmt the test. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
f21197f081 Store the thread name. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
52184193c3 Fix comments in TLS. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
ed9c7d168b Report that we do not support foreign thread local statics. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
1f33f04fd4 Move pthread_create and related shims to a separate file. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
aef4c95599 Fix the problem of sending pointed to thread local statics. Add a regression test. 2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
92946b5a9c Add a test for thread locals. 2020-04-27 14:23:32 -07:00