mirror of
https://github.com/opencv/opencv.git
synced 2024-12-04 00:39:11 +08:00
Merge pull request #20803 from alalek:core_parallel_workaround_tsan
This commit is contained in:
commit
b1a772d194
@ -615,6 +615,11 @@ void ThreadPool::run(const Range& range, const ParallelLoopBody& body, double ns
|
|||||||
{
|
{
|
||||||
WorkerThread& thread = *(threads[i].get());
|
WorkerThread& thread = *(threads[i].get());
|
||||||
if (
|
if (
|
||||||
|
#if defined(__clang__) && defined(__has_feature)
|
||||||
|
#if __has_feature(thread_sanitizer)
|
||||||
|
1 || // Robust workaround to avoid data race warning of `thread.job`
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
#if !defined(CV_USE_GLOBAL_WORKERS_COND_VAR)
|
#if !defined(CV_USE_GLOBAL_WORKERS_COND_VAR)
|
||||||
thread.isActive ||
|
thread.isActive ||
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user