1 // RUN: %clangxx_tsan -O1 %s -o %t && %t | FileCheck %s
2 // Regtest for https://code.google.com/p/thread-sanitizer/issues/detail?id=40
3 // This is a correct program and tsan should not report a race.
8 __attribute__((noinline
))
14 void *Thread1(void *p
) {
15 long res
= foo((long)p
);
22 pthread_create(&t
, 0, Thread1
, 0);