hanchenye-llvm-project/compiler-rt/test/tsan
Dmitry Vyukov 1d9b5e6ece tsan: fix handling of condition variable destruction
POSIX states that "It shall be safe to destroy an initialized condition
variable upon which no threads are currently blocked", and later clarifies
"A condition variable can be destroyed immediately after all the threads
that are blocked on it are awakened) (in examples section). Tsan reported
such destruction as a data race.
Fixes https://llvm.org/bugs/show_bug.cgi?id=23616
Reviewed in http://reviews.llvm.org/D10693

llvm-svn: 241082
2015-06-30 17:23:29 +00:00
..
Linux [Tsan] Make the mutex_robust tests Linux-specific 2014-10-15 12:43:04 +00:00
Unit
libcxx [TSan] Build TSan-instrumented version of libcxx and use it in lit tests. 2014-05-13 22:30:16 +00:00
CMakeLists.txt [sanitizer][MIPS] Fix warnings on MIPS 2015-04-10 09:45:22 +00:00
aligned_vs_unaligned_race.cc tsan: properly instrument unaligned accesses 2015-01-27 20:19:12 +00:00
allocator_returns_null.cc Fix typos 2014-05-15 02:22:34 +00:00
annotate_happens_before.cc tsan: add test for ANNOTATE_HAPPENS_BEFORE/AFTER annotations 2015-01-27 13:03:18 +00:00
atexit.cc tsan: more precise handling of atexit callbacks 2014-09-02 14:22:31 +00:00
atexit2.cc tsan: fix crash when a program registers zillions of atexit callbacks 2014-09-17 00:12:50 +00:00
atomic_free.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
atomic_free2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
atomic_norace.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
atomic_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
atomic_stack.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
barrier.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench.h tsan: reduce default number of threads in benchmarks 2014-03-24 15:23:05 +00:00
bench_acquire_only.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_acquire_release.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_local_mutex.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_mutex.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_release_only.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_rwmutex.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_shadow_flush.cc tsan: improve shadow flush benchmark 2014-07-26 16:40:33 +00:00
bench_single_writer.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
bench_ten_mutexes.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
benign_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
blacklist.cc [TSan] Make lit-tests more self-contained 2014-06-06 21:04:55 +00:00
blacklist2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
cond.c Add %run to all lit tests 2014-04-30 21:34:17 +00:00
cond_cancel.c tsan: handle async signals while blocked in pthread_cond_wait 2015-04-08 07:48:52 +00:00
cond_destruction.cc tsan: fix handling of condition variable destruction 2015-06-30 17:23:29 +00:00
cond_race.cc [TSan] Prepare TSan tests for splitting tsan_cxx library. 2015-04-27 22:08:08 +00:00
cond_version.c Add %run to all lit tests 2014-04-30 21:34:17 +00:00
deadlock_detector_stress_test.cc tsan: fix parsing of second_deadlock_stack flag 2015-04-14 10:32:33 +00:00
deep_stack1.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
default_options.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
deflake.bash tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
dl_iterate_phdr.cc tsan: fix false positive between dlopen and dl_iterate_phdr 2015-06-24 19:49:32 +00:00
dlclose.cc tsan: exclude unsupported test from test_output.sh script 2014-11-19 10:46:23 +00:00
fd_close_norace.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
fd_close_norace2.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fd_dup_norace.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fd_dup_norace2.cc tsan: fix flaky test 2015-06-29 13:56:31 +00:00
fd_dup_race.cc tsan: fix handling of dup2 2015-06-25 20:32:04 +00:00
fd_location.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
fd_pipe_norace.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fd_pipe_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
fd_socket_connect_norace.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fd_socket_norace.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fd_socketpair_norace.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fd_stdout_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
fork_atexit.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
fork_deadlock.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
fork_multithreaded.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
fork_multithreaded3.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
free_race.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
free_race.c.supp
free_race2.c tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
getline_nohang.cc [Tsan] Fix the getline_nohang.cc test to build on FreeBSD 2014-10-10 07:07:26 +00:00
global_race.cc [TSan][MIPS64] Fix few more test cases for MIPS64 2015-02-20 09:32:45 +00:00
global_race2.cc [TSan][MIPS64] Fix few more test cases for MIPS64 2015-02-20 09:32:45 +00:00
global_race3.cc [TSan][MIPS64] Fix few more test cases for MIPS64 2015-02-20 09:32:45 +00:00
halt_on_error.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
heap_race.cc [tsan] deflakify one more tsan test 2015-05-14 20:27:12 +00:00
ignore_free.cc [TSan] Prepare TSan tests for splitting tsan_cxx library. 2015-04-27 22:08:08 +00:00
ignore_lib0.cc Fix suppressions file usage 2014-12-18 18:25:18 +00:00
ignore_lib0.cc.supp
ignore_lib1.cc Fix suppressions file usage 2014-12-18 18:25:18 +00:00
ignore_lib1.cc.supp
ignore_lib2.cc Fix suppressions file usage 2014-12-18 18:25:18 +00:00
ignore_lib2.cc.supp
ignore_lib3.cc Fix suppressions file usage 2014-12-18 18:25:18 +00:00
ignore_lib3.cc.supp
ignore_lib_lib.h
ignore_malloc.cc [TSan] Prepare TSan tests for splitting tsan_cxx library. 2015-04-27 22:08:08 +00:00
ignore_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
ignore_sync.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
inlined_memcpy_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
inlined_memcpy_race2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
interface_atomic_test.c Add %run to all lit tests 2014-04-30 21:34:17 +00:00
java.h tsan: don't print external PCs in reports 2015-06-24 13:04:12 +00:00
java_alloc.cc tsan: refactor storage of meta information for heap blocks and sync objects 2014-05-29 13:50:54 +00:00
java_finalizer.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_heap_init.cc tsan: fix crash during __tsan_java_move 2015-03-12 11:24:16 +00:00
java_lock.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_lock_move.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_lock_rec.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_lock_rec_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_move_overlap.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_move_overlap_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_race.cc tsan: deflake a test 2015-04-20 10:35:21 +00:00
java_race_move.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_race_pc.cc tsan: add memory access functions that accept pc 2015-05-05 08:09:46 +00:00
java_rwlock.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
java_symbolization.cc tsan: don't print external PCs in reports 2015-06-24 13:04:12 +00:00
java_volatile.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
large_malloc_meta.cc tsan: fix unbounded memory consumption for large mallocs 2015-06-24 11:51:41 +00:00
lit.cfg [Tsan] Enable thread sanitizer tests on FreeBSD 2014-10-27 11:28:53 +00:00
lit.site.cfg.in [TSan] Build TSan-instrumented version of libcxx and use it in lit tests. 2014-05-13 22:30:16 +00:00
load_shared_lib.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
longjmp.cc [TSan][MIPS] XFAIL long jump tests for MIPS64 2015-05-08 12:58:03 +00:00
longjmp2.cc [TSan][MIPS] XFAIL long jump tests for MIPS64 2015-05-08 12:58:03 +00:00
longjmp3.cc [TSan][MIPS] XFAIL long jump tests for MIPS64 2015-05-08 12:58:03 +00:00
longjmp4.cc [TSan][MIPS] XFAIL long jump tests for MIPS64 2015-05-08 12:58:03 +00:00
malloc_overflow.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
malloc_stack.cc [TSan] Prepare TSan tests for splitting tsan_cxx library. 2015-04-27 22:08:08 +00:00
map32bit.cc [TSan][MIPS64] Fix few more test cases for MIPS64 2015-02-20 09:32:45 +00:00
memcpy_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mmap_large.cc [Tsan] Fix the mmap_large.cc test to build on FreeBSD 2015-03-23 19:40:59 +00:00
mmap_stress.cc tsan: fix a bug in MetaMap::ResetRange 2015-03-12 12:48:19 +00:00
mop1.c tsan: fix a bug memory access handling 2015-04-28 18:08:42 +00:00
mop_with_offset.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mop_with_offset2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
must_deadlock.cc [tsan] add a printf to a test 2014-07-14 15:52:33 +00:00
mutex_bad_read_lock.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
mutex_bad_read_unlock.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
mutex_bad_unlock.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
mutex_cycle2.c Fix suppressions file usage 2014-12-18 18:25:18 +00:00
mutex_destroy_locked.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
mutex_double_lock.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
mutexset1.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset3.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset4.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset5.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset6.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset7.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
mutexset8.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
printf-1.c Add %run to all lit tests 2014-04-30 21:34:17 +00:00
pthread_atfork_deadlock.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_barrier.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_barrier2.c tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
race_on_heap.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
race_on_mutex.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_mutex2.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_puts.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_read.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_speculative_load.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_on_write.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
race_top_suppression.cc tsan: implement suppressions for top frame only 2015-06-29 14:38:31 +00:00
race_top_suppression1.cc tsan: implement suppressions for top frame only 2015-06-29 14:38:31 +00:00
race_with_finished_thread.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
real_deadlock_detector_stress_test.cc tsan: fix failing CHECK In deadlock detector 2014-12-18 14:02:28 +00:00
restore_stack.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
setuid.c tsan: support setuid call 2015-04-23 09:33:27 +00:00
setuid2.c tsan: add another test for setuid 2015-04-29 17:22:43 +00:00
signal_cond.cc tsan: handle async signals while blocked in pthread_cond_wait 2015-04-08 07:48:52 +00:00
signal_errno.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
signal_longjmp.cc [TSan][MIPS] XFAIL long jump tests for MIPS64 2015-05-08 12:58:03 +00:00
signal_malloc.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
signal_recursive.cc [tsan] Disable a flaky test. 2015-06-04 18:28:35 +00:00
signal_reset.cc tsan: fix data races between signal handler and sigaction 2014-12-18 18:31:47 +00:00
signal_sync.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
signal_thread.cc tsan: add an additional test for signal handlers 2014-12-18 18:40:52 +00:00
signal_write.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
sigsuspend.cc tsan: fix false positive related to signals 2014-10-15 08:56:43 +00:00
simple_race.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
simple_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
simple_stack.c Fix up test cases to account for improved column fidelity provided by clang 2015-01-25 04:39:06 +00:00
simple_stack2.cc Fix up test cases to account for improved column fidelity provided by clang 2015-01-25 04:39:06 +00:00
sleep_sync.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
sleep_sync2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
stack_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
stack_race2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
stack_sync_reuse.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
static_init1.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
static_init2.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
static_init3.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
static_init4.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
static_init5.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
static_init6.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
sunrpc.cc [Tsan] Fix the sunrpc.cc test to build on FreeBSD 2014-10-15 12:47:48 +00:00
suppress_same_address.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
suppress_same_stacks.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
suppressions_global.cc Fix suppressions file usage 2014-12-18 18:25:18 +00:00
suppressions_global.cc.supp
suppressions_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
suppressions_race.cc.supp
suppressions_race2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
suppressions_race2.cc.supp
test.h [Tsan] Fix test.h to work on FreeBSD 2015-03-13 14:08:55 +00:00
test_output.sh tsan: don't add -pie when compiling tests 2014-11-19 10:45:53 +00:00
thread_detach.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
thread_detach2.c tsan: fix handling of pthread_detach 2015-04-20 10:35:10 +00:00
thread_end_with_ignore.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
thread_end_with_ignore2.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
thread_end_with_ignore3.cc tsan: make positive tests more robust 2014-05-30 14:08:51 +00:00
thread_leak.c Add %run to all lit tests 2014-04-30 21:34:17 +00:00
thread_leak2.c Add %run to all lit tests 2014-04-30 21:34:17 +00:00
thread_leak3.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
thread_leak4.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
thread_leak5.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
thread_name.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
thread_name2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
tiny_race.c tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
tls_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
tls_race2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
tsan-vs-gvn.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
unaligned_norace.cc tsan: properly instrument unaligned accesses 2015-01-27 20:19:12 +00:00
unaligned_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
vfork.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
virtual_inheritance_compile_bug.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
vptr_benign_race.cc Add %run to all lit tests 2014-04-30 21:34:17 +00:00
vptr_harmful_race.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
vptr_harmful_race2.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
vptr_harmful_race3.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
vptr_harmful_race4.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00
write_in_reader_lock.cc tsan: remove sleeps from tests 2015-01-21 13:50:02 +00:00