ubsan: if the frontend didn't provide us with a source location, try to work
one out from the return address. Currently, we can only resolve this address to
a file and line number if we have an external symbolizer.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170407 91177308-0d34-0410-b5e6-96231b3b80d8
Don't escape %s in printf usage message; it's not written by printf.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170413 91177308-0d34-0410-b5e6-96231b3b80d8
ubsan: When diagnosing something wrong somewhere in memory, emit a note
pointing at the bad location and a snippet of nearby memory values. This is
strictly best-effort; reading these bytes to display the note could lead to a
seg fault, and that's explicitly OK.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170415 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: describe "file descriptor" location


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170417 91177308-0d34-0410-b5e6-96231b3b80d8
[asan] add some colors to asan output if printing to tty (following ubsan)

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170418 91177308-0d34-0410-b5e6-96231b3b80d8
ubsan: Demangle class names, and be more informative when a reinterpret_cast
has got us to the wrong offset within an object.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170423 91177308-0d34-0410-b5e6-96231b3b80d8
[Sanitizer] Expose StackTrace::GetPreviousInstructionPc() to get PC of call instruction from return address

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170424 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: remove TSAN_OPTIONS from the script
The runtime skips atexit sleep if there are no threads now,
so it must be fast w/o it.
Allows to specify own TSAN_OPTIONS for the tests.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170426 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: add io_sync flag that controls amount of IO synchronization


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170427 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: add signalfd() and inotify_init() interceptors


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170429 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: warn about reports from signal handlers


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170430 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: intercept fork() to prevent false race reports on fd's


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170433 91177308-0d34-0410-b5e6-96231b3b80d8
[sanitizer] fix LargeMmapAllocator::GetBlockBegin

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170434 91177308-0d34-0410-b5e6-96231b3b80d8
[sanitizer] one more stability fix in 64-bit allocator

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170498 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: fix -Wgnu warnings


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170499 91177308-0d34-0410-b5e6-96231b3b80d8
[Sanitizer] implement internal_isatty on Windows

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170507 91177308-0d34-0410-b5e6-96231b3b80d8
[asan] asan_allocator2: improve FindHeapChunkByAddress to find memory chunks to the left of a given address. Almost all tests pass with the new allocator now, only 6 are left to fix.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170511 91177308-0d34-0410-b5e6-96231b3b80d8
[Sanitizer] add missing header on Windows

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170514 91177308-0d34-0410-b5e6-96231b3b80d8
tsan: add lint check back into presubmit script


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@170515 91177308-0d34-0410-b5e6-96231b3b80d8
[TSan] build only gtest-all.o when building TSan unit tests

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