tsan: improve error message for Go

llvm-svn: 200914
This commit is contained in:
Dmitry Vyukov 2014-02-06 09:22:29 +00:00
parent 12ae04bd17
commit a5d1fcfde1
1 changed files with 5 additions and 0 deletions

View File

@ -130,8 +130,13 @@ u32 ThreadRegistry::CreateThread(uptr user_id, bool detached, u32 parent_tid,
tctx = context_factory_(tid); tctx = context_factory_(tid);
threads_[tid] = tctx; threads_[tid] = tctx;
} else { } else {
#ifndef SANITIZER_GO
Report("%s: Thread limit (%u threads) exceeded. Dying.\n", Report("%s: Thread limit (%u threads) exceeded. Dying.\n",
SanitizerToolName, max_threads_); SanitizerToolName, max_threads_);
#else
Printf("race: limit on %u simultaneously alive goroutines is exceeded,"
" dying\n", max_threads_);
#endif
Die(); Die();
} }
CHECK_NE(tctx, 0); CHECK_NE(tctx, 0);