summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorPavel Labath <labath@google.com>2016-07-12 09:37:55 +0000
committerPavel Labath <labath@google.com>2016-07-12 09:37:55 +0000
commitdc15f1d7b84aa24dc3666f566bff95ebd27cfbbd (patch)
tree9f394bc273ebe1de24fb04bfc63d2d59b1d90ee2 /llvm/lib/CodeGen
parent402c8c07166146de29cdc6542e59d46a400b1e01 (diff)
downloadbcm5719-llvm-dc15f1d7b84aa24dc3666f566bff95ebd27cfbbd.tar.gz
bcm5719-llvm-dc15f1d7b84aa24dc3666f566bff95ebd27cfbbd.zip
Fix a race on process exit
Summary: Process::SetExitStatus was popping the process io handler and resetting m_process_input_reader shared pointer, which is not a safe thing to do as the function is called asynchronously and other threads may be accessing the member variable. (E.g. if the process terminates really quickly, the private state thread might only be in the process of pushing the handler on the stack. Sometimes, this leads to deadlock, as the shared pointer's state gets corrupted by the concurrent access. Since the IOHandler will be popped anyway in Process:HandleProcessStateChangedEvent when the exited event gets processed, doing the same in SetExitStatus seems to be unnecessary. Reviewers: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D22209 llvm-svn: 275165
Diffstat (limited to 'llvm/lib/CodeGen')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud