Sergey Matveev
22614e5e3f
[sanitizer] Fix memory leak in sanitizer_common discovered by LeakSanitizer.
...
llvm-svn: 185536
2013-07-03 13:45:13 +00:00
Evgeniy Stepanov
1bd0fe447f
[sanitizer] Fix Android build.
...
llvm-svn: 185432
2013-07-02 14:51:31 +00:00
Evgeniy Stepanov
aa23bd83e5
[msan] Intercept mempcpy, wmempcpy.
...
llvm-svn: 185431
2013-07-02 14:49:24 +00:00
Evgeniy Stepanov
69a387e6ae
[sanitizer] Fix GLOB_NOMATCH behaviour and refactor the interceptor a bit.
...
llvm-svn: 185428
2013-07-02 14:08:52 +00:00
Evgeniy Stepanov
165d759a6a
[sanitizer] Intercept mbtowc, mbrtowc, get_current_dir_name.
...
Move getcwd to common interceptors.
llvm-svn: 185424
2013-07-02 13:34:44 +00:00
Evgeniy Stepanov
1df4dfe87a
[sanitizer] Intercept setlocale.
...
llvm-svn: 185416
2013-07-02 09:23:45 +00:00
Alexey Samsonov
4798a08df8
[ASan] try to fix Windows build
...
llvm-svn: 185345
2013-07-01 16:38:38 +00:00
Alexey Samsonov
9857ca2564
[ASan] Properly disable strict init-order checking when pthread_create is called
...
llvm-svn: 185342
2013-07-01 16:16:41 +00:00
Evgeniy Stepanov
654688bed5
[msan] Intercept stpcpy.
...
llvm-svn: 185340
2013-07-01 15:19:37 +00:00
Evgeniy Stepanov
8a4e24ea8b
[sanitizer] Intercept getnameinfo.
...
llvm-svn: 185338
2013-07-01 13:51:31 +00:00
Alexey Samsonov
7a1ad5e605
Change __sanitizer_symbolize_demangle hook return type to 'int'
...
llvm-svn: 185326
2013-07-01 11:20:56 +00:00
Alexander Potapenko
0fde89f2aa
[ASan] Cache atos processes to make Darwin symbolication faster.
...
Patch by Jesse Ruderman<jruderman@gmail.com>
llvm-svn: 185325
2013-07-01 10:51:31 +00:00
Sergey Matveev
6b5a492091
[sanitizer] Use the correct macro to check glibc version.
...
llvm-svn: 185324
2013-07-01 10:15:29 +00:00
Alexey Samsonov
c3832f7788
[ASan] Add sanity test for asan_symbolize.py script
...
llvm-svn: 185318
2013-07-01 09:15:19 +00:00
Evgeniy Stepanov
d6e856f722
[sanitizer] Fix build with older kernels.
...
PTRACE_SETREGSET & PTRACE_GETREGSET may be missing from linux headers.
llvm-svn: 185317
2013-07-01 09:10:34 +00:00
Alexey Samsonov
cc510707af
[ASan] Remove leading underscores from function names in output tests
...
llvm-svn: 185315
2013-07-01 08:41:45 +00:00
Alexey Samsonov
8918140809
Hide mlock/munlock info message under verbosity flag.
...
llvm-svn: 185314
2013-07-01 08:25:29 +00:00
Alexey Samsonov
dd8872b1d2
Always set -m32/-m64 flags for targeting i386/x86_64 respectively. Apparently, there are platforms where the clang defaults are different from gcc
...
llvm-svn: 185287
2013-06-30 16:21:32 +00:00
Alexey Samsonov
e71f37c1cd
Define the path to llvm-symbolizer tool in a common config to reduce copy-paste
...
llvm-svn: 185286
2013-06-30 14:47:38 +00:00
Richard Smith
079fe209f5
Fix typo found by Clang fix for extern "C" function handling.
...
llvm-svn: 185234
2013-06-28 22:28:37 +00:00
Alexey Samsonov
13f89cd19b
[ASan] Remove %symbolize from lit tests: we now use external symbolizer instead of python script
...
llvm-svn: 185163
2013-06-28 15:52:44 +00:00
Sergey Matveev
202881d1fe
[lsan] Fix build again.
...
llvm-svn: 185157
2013-06-28 15:23:15 +00:00
Sergey Matveev
b3fa575f7b
[lsan] Fix build.
...
llvm-svn: 185156
2013-06-28 15:18:06 +00:00
Sergey Matveev
6672004c47
[lsan] When verbosity > 1, always print suppressions and summary (even if no leaks found).
...
Also fix an output bug.
llvm-svn: 185153
2013-06-28 15:05:16 +00:00
Sergey Matveev
2b19ee3da8
[lsan] Add suppression support.
...
llvm-svn: 185152
2013-06-28 14:38:31 +00:00
Evgeniy Stepanov
a127039258
[sanitizer] Disable all ptrace-related definitions on Android.
...
llvm-svn: 185150
2013-06-28 14:18:10 +00:00
Alexey Samsonov
002d764f21
[ASan] Migrate lit tests to external symbolizer from asan_symbolize.py script
...
llvm-svn: 185148
2013-06-28 12:50:12 +00:00
Alexey Samsonov
6a5b0758ec
Demangle names using pluggable internal symbolizer if possible
...
llvm-svn: 185146
2013-06-28 12:30:24 +00:00
Evgeniy Stepanov
4aef0ee57d
[sanitizer] Fix an unfortunate typo and disable ptrace interception on Android.
...
llvm-svn: 185145
2013-06-28 12:16:03 +00:00
Alexey Samsonov
28e68f9f2f
Pass --default-arch flag to external symbolizer. Fix line lengths.
...
llvm-svn: 185144
2013-06-28 12:13:31 +00:00
Evgeniy Stepanov
dec0f76c14
[sanitizer] Intercept ptrace.
...
llvm-svn: 185142
2013-06-28 11:02:43 +00:00
Alexander Potapenko
2b064a2b4e
[ASan][OSX] Make sure the zones created by malloc_create_zone() are write-protected.
...
Add a test.
llvm-svn: 185140
2013-06-28 10:01:09 +00:00
Alexander Potapenko
593f833e9b
[ASan][OSX] Fix the incorrect malloc_create_zone() implementation that led to out-of-bounds mprotect()s
...
(https://code.google.com/p/address-sanitizer/issues/detail?id=203 )
Add a test.
llvm-svn: 185138
2013-06-28 09:21:31 +00:00
Bill Wendling
28e84fc53e
Revert hack that omits errno on Darwin platforms. We now have an acceptable 'errno' header.
...
llvm-svn: 185106
2013-06-27 21:17:53 +00:00
Bill Wendling
4ddc302879
Declare 'strerror' so that we can use it with errno.
...
llvm-svn: 185105
2013-06-27 21:17:24 +00:00
Bill Wendling
bc922e5a5f
Add 'errno.h' to the Darwin SDK.
...
llvm-svn: 185104
2013-06-27 21:17:06 +00:00
Sergey Matveev
9450108430
[sanitizer] Support padding with spaces in Printf.
...
llvm-svn: 185082
2013-06-27 15:30:44 +00:00
Sergey Matveev
1c34897887
[lsan] Fix flaky test.
...
llvm-svn: 185079
2013-06-27 14:24:07 +00:00
Dmitry Vyukov
d2cd2d018f
tsan: revert dynamic symbols file to the old incorrect one
...
full proper list of dynamic symbols crashes old gold (see bug 16468).
the culprit is 'memcpy' function, if it's added to syms file, gold crashes
llvm-svn: 185078
2013-06-27 13:56:37 +00:00
Dmitry Vyukov
b7c6f49364
tsan: remove non-existent functions from syms file
...
llvm-svn: 185077
2013-06-27 13:52:50 +00:00
Evgeniy Stepanov
f5cae53057
[msan] Optionally disable 2 tests (dlopen & gethostbyname).
...
llvm-svn: 185076
2013-06-27 13:21:00 +00:00
Evgeniy Stepanov
815d3232a7
[sanitizer] Fix dirent interceptors.
...
The new version reads d_reclen for (struct dirent) size.
llvm-svn: 185067
2013-06-27 09:37:27 +00:00
Alexey Samsonov
895784a5b0
[LSan] Add the way to disable LSan at link time
...
llvm-svn: 185066
2013-06-27 09:35:50 +00:00
Alexey Samsonov
ecdcf11bd6
[TSan] try to fix Go build
...
llvm-svn: 185063
2013-06-27 07:57:53 +00:00
Alexey Samsonov
ed4594b76a
[MSan] Rename __msan_unpoision_param to __msan::UnpoisonParam - it shouldn't be in interface
...
llvm-svn: 185062
2013-06-27 07:50:56 +00:00
Sergey Matveev
0b2ffe30e4
[tsan] Fix build.
...
llvm-svn: 184963
2013-06-26 16:49:34 +00:00
Bob Wilson
c4b26ad006
Revert "Temporarily disable building the armv7 variants of profile_ios on"
...
This reverts commit r184816. With Chandler's change in r184929, this should
no longer be necessary.
llvm-svn: 184961
2013-06-26 16:35:16 +00:00
Sergey Matveev
d109eb052b
[tsan] Move some suppressions-related code to common.
...
Factor out code to be reused in LSan. Also switch from linked list to vector.
llvm-svn: 184957
2013-06-26 15:37:14 +00:00
Evgeniy Stepanov
06d6c25141
[sanitizer] readdir and readdir_r interceptors.
...
llvm-svn: 184950
2013-06-26 15:00:53 +00:00
Kostya Serebryany
6a068a715d
[asan] initialize fake_stack lazily and increase its maximal size. This makes -fsanitize=address,use-after-return more robust: all SPEC tests pass now. In the default mode thread stacks become a bit smaller.
...
llvm-svn: 184934
2013-06-26 12:16:05 +00:00