[ASan] Fix leaks in ASan tests found by LSan

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186577 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: treat SIGSYS as synchronous signal
It is required for chromium sandboxing code.
From the description it seems to be indeed synchronous -- called back on syscall with incorrect arguments,
but seems to be unused in practice. So this should be fine.



git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186579 91177308-0d34-0410-b5e6-96231b3b80d8
[lsan] Add __lsan_do_leak_check() to the public interface.

Let users override the normal behavior to run leak checking earlier in
the process. Also fix a couple nits here and there.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186581 91177308-0d34-0410-b5e6-96231b3b80d8
Use --driver-mode=g++ instead of -ccc-cxx; required after Clang r186605


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186607 91177308-0d34-0410-b5e6-96231b3b80d8
Fix another instance of -ccc-cxx vs. --driver-mode=g++


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186609 91177308-0d34-0410-b5e6-96231b3b80d8
[lsan] Print direct leaks first.

Direct leaks are higher priority, so it makes sense to have them on top.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186819 91177308-0d34-0410-b5e6-96231b3b80d8
[lsan] Make __lsan_do_leak_check() honor the detect_leaks flag.

Also move detect_leaks to common flags.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@186821 91177308-0d34-0410-b5e6-96231b3b80d8