[llvm-commits] [compiler-rt] r164999 - /compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc
Dmitry Vyukov
dvyukov at google.com
Tue Oct 2 05:07:16 PDT 2012
Author: dvyukov
Date: Tue Oct 2 07:07:16 2012
New Revision: 164999
URL: http://llvm.org/viewvc/llvm-project?rev=164999&view=rev
Log:
tsan: wait for pending reports before exit
Modified:
compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc
Modified: compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc?rev=164999&r1=164998&r2=164999&view=diff
==============================================================================
--- compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc (original)
+++ compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc Tue Oct 2 07:07:16 2012
@@ -219,6 +219,10 @@
Context *ctx = __tsan::ctx;
bool failed = false;
+ // Wait for pending reports.
+ ctx->report_mtx.Lock();
+ ctx->report_mtx.Unlock();
+
ThreadFinalize(thr);
if (ctx->nreported) {
More information about the llvm-commits
mailing list