[ASan] Split throw_catch tests into two files: throw/catch + longjmp

Also add some more assertions into these tests

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213642 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan] Simplify exception/longjmp tests even further

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213646 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan/Win] Add handling of C++ exceptions to the RTL

Also add a longjmp() test

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213649 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan/Win] Handle SEH exceptions (best-effort, similar to longjmp)

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213654 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan/Win] Add SEH handling to the DLL thunk as well

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213656 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan/Win tests] Don't generate debug info where it is not needed

Otherwise it results in flaky tests

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213667 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan/Win tests] Bring back -GS- as SEH tests fail otherwise

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213668 91177308-0d34-0410-b5e6-96231b3b80d8
Include assembly files in builtins library build

The CMake assembler build system ignores the .S assembly files in builtins
library build. This patch fixes the issue.

Patch by: Sumanth Gundapaneni

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213684 91177308-0d34-0410-b5e6-96231b3b80d8
Fix incompatible assembly in ARM builtins library

Convert the CBNZ backward branch instruction to CMP and BNE
avoiding illegal backwards branch and making the assembly code
in synh-ops.h to be UAL compliant.

Patch by: Sumanth Gundapaneni

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213685 91177308-0d34-0410-b5e6-96231b3b80d8
[Sanitizer] Disable Wframe-larger-than on PowerPC hosts

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213702 91177308-0d34-0410-b5e6-96231b3b80d8
Revert "Include assembly files in builtins library build"

This reverts commit r213684, since it was breaking the compiler-rt
build and the sanitizers' bot.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213724 91177308-0d34-0410-b5e6-96231b3b80d8
[UBSan] Introduce UBSAN_OPTIONS environment variable.

If UBSan is run in a standalone mode (w/o any other sanitizer), it
still uses functions from sanitizer_common, some of which depend on
the value of runtime flags. Allow to override the default values of these
flags with UBSAN_OPTIONS variable. In particular, UBSAN_OPTIONS=symbolize=0
can be used to turn off online symbolization.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213782 91177308-0d34-0410-b5e6-96231b3b80d8
[UBSan] Add the ability to dump call stacks to -fsanitize=vptr

This change introduces the first UBSan-specific runtime flag: print_stacktrace
(off by default). It can be set in UBSAN_OPTIONS to unwind and print call stacks
in addition to diagnostic messages. For now these stacks are printed only
in vptr checker.

This change is based on http://reviews.llvm.org/D4410 by Byoungyoung Lee!


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213783 91177308-0d34-0410-b5e6-96231b3b80d8
Fix unused-variable warning

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213786 91177308-0d34-0410-b5e6-96231b3b80d8
Build libcxx-tsan only if TSan is supported on host architecture

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213791 91177308-0d34-0410-b5e6-96231b3b80d8
Add FreeBSD support to Asan test cases that use mmap() with MAP_ANON
Differential Revision: http://reviews.llvm.org/D4561


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213858 91177308-0d34-0410-b5e6-96231b3b80d8
[lsan] Follow-up for r213518: replace MAP_ANONYMOUS with MAP_ANON
(despite it's deprecated on Linux) to remove the ifdefs.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213929 91177308-0d34-0410-b5e6-96231b3b80d8
Support traversing ELF objects for sanitizers needs on FreeBSD in 32-bit mode
Differential Revision: http://reviews.llvm.org/D4656


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213940 91177308-0d34-0410-b5e6-96231b3b80d8
Allow initialization of Asan interceptors before the general Asan initialization takes place on FreeBSD
Differential Revision: http://reviews.llvm.org/D4496


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@213941 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: fix and make faster GetRSS
It is currently broken because it reads a wrong value from profile (heap instead of total).
Also make it faster by reading /proc/self/statm. Reading of /proc/self/smaps
can consume more than 50% of time on beefy apps if done every 100ms.



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