Alexey Samsonov
c3f61d8eec
[ASan] Fix unit test headers. Add an option to change substitute asan_test_config.h file
...
llvm-svn: 164821
2012-09-28 12:24:23 +00:00
Alexey Samsonov
2d9899b2ce
[ASan] use llvm-symbolizer (in offline mode) in ASan output tests on Linux
...
llvm-svn: 164819
2012-09-28 11:05:41 +00:00
Evgeniy Stepanov
9792396a06
[asan] Change defaults for Android target.
...
This way building without -DASAN_* in CFLAGS produces working binaries.
llvm-svn: 164816
2012-09-28 10:07:53 +00:00
Evgeniy Stepanov
cb9cf0f907
Add a missing const qualifier.
...
llvm-svn: 164773
2012-09-27 13:21:08 +00:00
Evgeniy Stepanov
f7f616ba66
Quick fix data/bss detection in TSan.
...
The old way breaks when a module's bss is adjacent to the [heap] vm area.
Both ways are not very reliable, though.
llvm-svn: 164772
2012-09-27 13:20:40 +00:00
Alexey Samsonov
b6879ce94c
[TSan] move replacement for new/delete back into tsan_interceptors
...
llvm-svn: 164764
2012-09-27 09:50:19 +00:00
Alexander Potapenko
3f6a5c1b2d
Fixed a number of gpylint warnings, added binary names filtering (useful for Chrome), minor fixes.
...
llvm-svn: 164695
2012-09-26 13:16:42 +00:00
Alexander Potapenko
59cc8776c4
Encapsulate the main loop into a class to allow reusing it.
...
llvm-svn: 164694
2012-09-26 12:12:41 +00:00
Alexander Potapenko
fa2a964540
Set --use-symbol-table=true as Alexey has already resolved the FIXME.
...
llvm-svn: 164693
2012-09-26 11:36:14 +00:00
Alexey Samsonov
789d4b2cd0
[TSan] fork external symbolizer before starting internal threads
...
llvm-svn: 164600
2012-09-25 12:35:47 +00:00
Alexey Samsonov
351d486df0
[TSan] one more attempt to fix sleep_sync test: call sleep in the spawned thread so that sleep-synchronization will be detected even if child thread is started late.
...
llvm-svn: 164488
2012-09-24 13:35:46 +00:00
Alexey Samsonov
313014694f
[TSan] Provide replacements for operators new/delete instead of declaring extern C functions with weirdly mangled names (same strategy is used in ASan).
...
llvm-svn: 164487
2012-09-24 13:19:47 +00:00
Alexey Samsonov
a555b3faf4
[ASan] Apply some ASan-relevant pieces of patch by Ruben Van Boxem. In the same time, remove ASan from CMake build on Windows after conversation with Timur. We don't want to support building ASan on Windows until it is in a working state.
...
llvm-svn: 164486
2012-09-24 11:43:40 +00:00
Alexey Samsonov
0659f72f7b
[TSan] increase sleep time in test to ensure correct event ordering
...
llvm-svn: 164483
2012-09-24 08:57:41 +00:00
Michael J. Spencer
c774095d44
[CMake][tsan] Compile .S files for tsan as C instead of CXX.
...
Using CXX breaks if you add -stdlib=libc++ to CMAKE_CXX_FLAGS.
llvm-svn: 164422
2012-09-21 22:39:39 +00:00
Alexey Samsonov
9e769a8d59
[Sanitizer] llvm-symbolizer: enable accessing symbol table (libObject is fixed in r164365) and replace string with std::string
...
llvm-svn: 164367
2012-09-21 10:54:14 +00:00
Eric Christopher
8539af7bbb
Both OpenBSD and Bitrig need to include machine/endian.h to get the
...
_BYTE_ORDER define.
Patch by David Hill.
llvm-svn: 164286
2012-09-20 06:19:20 +00:00
Alexey Samsonov
bc0b3f43d1
[ASan] Include ASan into CMake build only on Linux, Mac and Windows
...
llvm-svn: 164224
2012-09-19 14:15:30 +00:00
Alexey Samsonov
1fba97d22d
[TSan] Add tsan to cmake build of compiler-rt only on Linux
...
llvm-svn: 164217
2012-09-19 13:11:13 +00:00
Alexey Samsonov
ea2fb08545
[ASan] make asan_symbolize script work if there is no llvm-symbolizer available
...
llvm-svn: 164214
2012-09-19 11:43:41 +00:00
Alexey Samsonov
52565d5491
[ASan] fix offline python symbolizer script to use llvm-symbolizer if possible
...
llvm-svn: 164209
2012-09-19 08:49:53 +00:00
Alexey Samsonov
11b9e97cd9
[ASan] cleanup: fix headers and lint warnings
...
llvm-svn: 164205
2012-09-19 07:07:46 +00:00
Dmitry Vyukov
8d8639bc55
tsan: fix gcc4.2.1 warning
...
llvm-svn: 164200
2012-09-19 04:45:14 +00:00
Dmitry Vyukov
c7bcaf8512
tsan: fix Go build
...
llvm-svn: 164198
2012-09-19 04:39:36 +00:00
Alexander Potapenko
431ea19327
Intercept signal() and sigaction() within the dynamic runtime on Mac.
...
Add a test that ensures that ASan does not allow to override the signal handlers.
llvm-svn: 164118
2012-09-18 12:49:51 +00:00
Alexey Samsonov
848abbd236
[TSan] s/uintptr_t/intptr_t in TSan test and enforce stack size limit in one of TSan output tests that somewhy fails otherwise
...
llvm-svn: 164116
2012-09-18 09:09:35 +00:00
Alexey Samsonov
3040830fcd
[TSan] fix a typo in test dependencies. Silence few remaining pedantic gcc warnings in TSan tests.
...
llvm-svn: 164115
2012-09-18 08:33:37 +00:00
Alexey Samsonov
731219551e
[Sanitizer] llvm-symbolizer: turn off symbol table lookup by default while getSymbolAddress from libObject returns wrong values
...
llvm-svn: 164113
2012-09-18 08:00:21 +00:00
Alexey Samsonov
8661465edd
[ASan] Move printing descriptions of heap addresses in error report from allocator internals to asan_report.cc.
...
llvm-svn: 164112
2012-09-18 07:38:10 +00:00
Alexey Samsonov
5a42ac5b0e
[Sanitizer] update lint checker script
...
llvm-svn: 164111
2012-09-18 07:26:51 +00:00
Alexey Samsonov
341e5bcb45
[TSan] port all output tests to lit and move them to lit_tests directory. This makes 'make check-tsan' command test both unit and output TSan tests. Old custom makefiles for running TSan tests are still functional as well.
...
llvm-svn: 164110
2012-09-18 07:23:54 +00:00
Kostya Serebryany
0a31ed1417
[tsan] fix the tsan allocator to handle any alignment
...
llvm-svn: 164107
2012-09-18 06:00:59 +00:00
Bill Wendling
b556d5f13c
Remove debugging code.
...
llvm-svn: 164052
2012-09-17 20:43:11 +00:00
Benjamin Kramer
7aa5b663ea
Update linux stdio.h to support the recent additions to GCDAProfiling.
...
Hopefully unbreaks compiler-rt build on linux.
llvm-svn: 164025
2012-09-17 10:23:05 +00:00
Alexey Samsonov
0fa3ea69e2
[TSan] move: rtl_tests->tests/rtl unit_tests->tests/unit to make a single root for gtest-based tests. Support running these tests from lit via check-tsan command.
...
llvm-svn: 164022
2012-09-17 10:02:17 +00:00
Alexey Samsonov
ff3f173e87
[TSan] If we detect an unlimited stack, try to re-exec with limited stack
...
llvm-svn: 164021
2012-09-17 09:14:11 +00:00
Alexey Samsonov
97ca306641
[Sanitizer] Hoist functions to get/set stack size and re-exec from memory-sanitizer branch to sanitizer_common
...
llvm-svn: 164020
2012-09-17 09:12:39 +00:00
Alexey Samsonov
3869b4b35a
[ASan] increase sleep time if ASan finds two bugs simultaneously to make sure full error report is printed
...
llvm-svn: 164018
2012-09-17 08:02:19 +00:00
Dmitry Vyukov
40c19aaf84
tsan: increase internal memory block limit 1GB->4GB
...
llvm-svn: 164011
2012-09-17 03:18:45 +00:00
Dmitry Vyukov
4d743f5346
tsan: reserve msb in stack depot id's (required for msan)
...
llvm-svn: 164010
2012-09-17 03:14:15 +00:00
Bill Wendling
06fb5f0cc2
Remove unused variable.
...
llvm-svn: 163930
2012-09-14 20:23:31 +00:00
Bill Wendling
66429fe1c7
Add support for reading the GCDA file and merging the arc information.
...
With the advent of the __llvm_gcov_flush function, we need to be able to merge
counts into the .gcda files in an intelligent manner. This involves reading the
file if it exists, adding the counts together, and then writing the results.
<rdar://problem/12185886>
llvm-svn: 163923
2012-09-14 18:55:32 +00:00
Evgeniy Stepanov
6c0850afa4
Remove some debugging code.
...
llvm-svn: 163881
2012-09-14 08:57:50 +00:00
Kostya Serebryany
5b0a8f3f53
[asan] fix the va_arg usage
...
llvm-svn: 163879
2012-09-14 06:52:46 +00:00
Kostya Serebryany
45d849c4bd
[asan] add asan option log_path=PATH to let users redirect asan reports to a file PATH.PID instead of stderr
...
llvm-svn: 163872
2012-09-14 04:35:14 +00:00
Alexey Samsonov
2b8de6a753
[TSan] support building TSan unittests in CMake
...
llvm-svn: 163797
2012-09-13 14:04:57 +00:00
Alexey Samsonov
a7df554138
[TSan] fix a typo in CMakeLists
...
llvm-svn: 163796
2012-09-13 14:02:40 +00:00
Alexey Samsonov
f0aa9148a2
[TSan] Use interface attribute for weak functions that may be overriden by user
...
llvm-svn: 163795
2012-09-13 13:34:09 +00:00
Alexey Samsonov
255f6a5f1a
[TSan] Add initial support for buidling ThreadSanitizer runtime library with CMake (currently the only supported platfrom is 64-bit Linux). This patch makes 'clang++ -fthread-sanitizer' work for both clang in the build tree and installed clang
...
llvm-svn: 163789
2012-09-13 12:18:41 +00:00
Alexey Samsonov
046248c509
[TSan] fix a bunch of warnings reported by pedantic gcc
...
llvm-svn: 163788
2012-09-13 11:54:41 +00:00