diff options
author | Fangrui Song <maskray@google.com> | 2019-04-25 11:33:30 +0000 |
---|---|---|
committer | Fangrui Song <maskray@google.com> | 2019-04-25 11:33:30 +0000 |
commit | f6a6290908dfcf4df6284c6d3eb94bb762e587fb (patch) | |
tree | d219644bd02a6fd4813bb02f415d5e0d728948df /lldb/packages/Python/lldbsuite/test/expression_command/call-function/TestCallStopAndContinue.py | |
parent | 9e8d0d981b0cb1e3cbd0260af4e3b1f44ddf7be2 (diff) | |
download | bcm5719-llvm-f6a6290908dfcf4df6284c6d3eb94bb762e587fb.tar.gz bcm5719-llvm-f6a6290908dfcf4df6284c6d3eb94bb762e587fb.zip |
Parallel: only allow the first TaskGroup to run tasks parallelly
Summary:
Concurrent (e.g. nested) llvm::parallel::for_each() may lead to dead
locks. See PR35788 (fixed by rLLD322041) and PR41508 (fixed by D60757).
When parallel_for_each() is about to return, in ~Latch() called by
~TaskGroup(), a thread (in the default executor) may block in
Latch::sync() waiting for Count to become zero. If all threads in the
default executor are blocked, it is a dead lock.
To fix this, force serial execution if the current TaskGroup is not the
first one. For a nested llvm::parallel::for_each(), this parallelizes
the outermost loop and serializes inner loops.
Differential Revision: https://reviews.llvm.org/D61115
llvm-svn: 359182
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/expression_command/call-function/TestCallStopAndContinue.py')
0 files changed, 0 insertions, 0 deletions