llvm-project/lldb
Vedant Kumar 0877dd14e4 [Driver] Force llvm to install its handlers before lldb's
Install llvm's signal handlers up front to prevent lldb's handlers from being
ignored. This is (hopefully) a stopgap workaround.

When lldb invokes an llvm API that installs signal handlers (e.g.
llvm::sys::RemoveFileOnSignal, possibly via a compiler embedded within lldb),
lldb's signal handlers are overriden if llvm is installing its handlers for the
first time.

To work around llvm's behavior, force it to install its handlers up front, and
*then* install lldb's handlers. In practice this is used to prevent lldb test
processes from exiting due to IO_ERR when SIGPIPE is received.

Note that when llvm installs its handlers, it 1) records the old handlers it
replaces and 2) re-installs the old handlers when its new handler is invoked.
That means that a signal not explicitly handled by lldb can fall back to being
handled by llvm's handler the first time it is received, and then by the
default handler the second time it is received.

Differential Revision: https://reviews.llvm.org/D69403
2019-10-25 11:19:10 -07:00
..
cmake [CMake] Move test dependency tracking into test/CMakeLists.txt 2019-10-24 14:47:07 -07:00
docs [CMake] Remove unused variable LLDB_TEST_CXX_COMPILER 2019-10-24 14:47:07 -07:00
examples Revert [heap.py] Add missing declaration for malloc_get_all_zones 2019-08-22 21:01:45 +00:00
include/lldb ValueObject: Fix a crash related to children address type computation 2019-10-25 17:49:06 +00:00
packages/Python/lldbsuite [lldb] Add nodebug attribute to import-std-module/sysroot test 2019-10-23 09:26:57 -07:00
resources [CMake] Revised LLDB.framework builds 2019-01-04 12:46:50 +00:00
scripts remove multi-argument form of PythonObject::Reset() 2019-10-22 02:32:37 +00:00
source Fix compilation error in ObjectFileMachO::ParseSymtab 2019-10-25 11:16:51 -07:00
test ValueObject: Fix a crash related to children address type computation 2019-10-25 17:49:06 +00:00
third_party/Python/module Increase timeout in pexpect to lower chances of tests failing under ASAN. 2019-10-10 16:16:49 +00:00
tools [Driver] Force llvm to install its handlers before lldb's 2019-10-25 11:19:10 -07:00
unittests fix PythonDataObjectsTest.TestExceptions on windows 2019-10-22 04:00:37 +00:00
utils [TableGen] Add asserts to make sure default values match property type 2019-10-25 10:18:38 -07:00
.arcconfig
.clang-format
.gitignore Add .noindex to the gitignore 2019-04-05 17:57:42 +00:00
CMakeLists.txt [CMake] Move LLDB_TEST_BUILD_DIRECTORY into test/CMakeLists.txt 2019-10-24 14:47:07 -07:00
CODE_OWNERS.txt [lldb][NFC] Cleanup mentions and code related to lldb-mi 2019-07-19 15:55:23 +00:00
LICENSE.TXT Fix typos throughout the license files that somehow I and my reviewers 2019-01-21 09:52:34 +00:00
use_lldb_suite_root.py