tsan: work around FileCheck feature that it does not accept empty input
llvm-svn: 171034
This commit is contained in:
parent
f6d8021520
commit
19969e5045
|
|
@ -25,6 +25,7 @@ int main() {
|
|||
pthread_create(&t[1], NULL, Thread2, NULL);
|
||||
pthread_join(t[0], NULL);
|
||||
pthread_join(t[1], NULL);
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@ int main() {
|
|||
pthread_create(&t[1], NULL, Thread2, NULL);
|
||||
pthread_join(t[0], NULL);
|
||||
pthread_join(t[1], NULL);
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ int main() {
|
|||
pthread_create(&t[1], NULL, Thread2, NULL);
|
||||
pthread_join(t[0], NULL);
|
||||
pthread_join(t[1], NULL);
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ int main() {
|
|||
pthread_join(t, 0);
|
||||
close(c);
|
||||
close(s);
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ int main() {
|
|||
close(c);
|
||||
close(s);
|
||||
pthread_join(t, 0);
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ int main() {
|
|||
pthread_create(&t[1], NULL, Thread2, NULL);
|
||||
pthread_join(t[0], NULL);
|
||||
pthread_join(t[1], NULL);
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ int main() {
|
|||
sleep(1);
|
||||
Global = 43;
|
||||
pthread_join(t, 0);
|
||||
return 0;
|
||||
printf("OK\n");
|
||||
}
|
||||
|
||||
// CHECK-NOT: WARNING: ThreadSanitizer: data race
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@ int main() {
|
|||
pthread_create(&th, 0, Thread, (void*)(jheap + kHeapSize / 4));
|
||||
stress(jheap);
|
||||
pthread_join(th, 0);
|
||||
printf("OK\n");
|
||||
return __tsan_java_fini();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ int main() {
|
|||
__tsan_java_mutex_unlock(lockaddr);
|
||||
pthread_join(th, 0);
|
||||
__tsan_java_free((jptr)jheap, kBlockSize);
|
||||
printf("OK\n");
|
||||
return __tsan_java_fini();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ int main() {
|
|||
__tsan_java_move(varaddr, varaddr2, kBlockSize);
|
||||
pthread_join(th, 0);
|
||||
__tsan_java_free(varaddr2, kBlockSize);
|
||||
printf("OK\n");
|
||||
return __tsan_java_fini();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ int main() {
|
|||
__tsan_java_mutex_unlock(lockaddr);
|
||||
pthread_join(th, 0);
|
||||
__tsan_java_free((jptr)jheap, kBlockSize);
|
||||
printf("OK\n");
|
||||
return __tsan_java_fini();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -22,9 +22,6 @@ test_file() {
|
|||
$COMPILER $SRC $CFLAGS -c -o $OBJ
|
||||
$COMPILER $OBJ $LDFLAGS -o $EXE
|
||||
RES=$($EXE 2>&1 || true)
|
||||
if [ "$3" != "" ]; then
|
||||
printf "%s\n" "$RES"
|
||||
fi
|
||||
printf "%s\n" "$RES" | FileCheck $SRC
|
||||
if [ "$3" == "" ]; then
|
||||
rm -f $EXE $OBJ
|
||||
|
|
|
|||
Loading…
Reference in New Issue