Timur Iskhodzhanov
07109b4161
[ASan/Win tests] Add a PR reference for the FileCheck bug
...
llvm-svn: 208807
2014-05-14 19:47:58 +00:00
Timur Iskhodzhanov
78dccb0822
Remove an unneeded stderr redirection
...
llvm-svn: 208805
2014-05-14 19:34:13 +00:00
Timur Iskhodzhanov
3653790410
Remove --check-prefix=CHECK as it's useless
...
llvm-svn: 208803
2014-05-14 19:31:56 +00:00
Timur Iskhodzhanov
2bdca20069
[ASan tests] Add the first Windows-only lit test
...
Reviewed at http://reviews.llvm.org/D3767
llvm-svn: 208802
2014-05-14 19:10:43 +00:00
Timur Iskhodzhanov
9de6fe7b83
[ASan tests] Get rid of SharedLibs/
...
llvm-svn: 208780
2014-05-14 14:41:38 +00:00
Timur Iskhodzhanov
b2e723e448
[ASan tests] Update relative paths from POSIX-only tests to their shared libraries
...
llvm-svn: 208778
2014-05-14 14:16:09 +00:00
Timur Iskhodzhanov
6a9121904d
[ASan tests] Create a Posix/ directory for tests that we don't plan to run on Windows
...
llvm-svn: 208777
2014-05-14 14:12:02 +00:00
Evgeniy Stepanov
99d3791a88
[sanitizer] Fix crash in getgrnam_r and similar interceptors.
...
When no matching record is found, getgrnam_r return 0 but sets result to NULL.
Should fix PR19734.
llvm-svn: 208773
2014-05-14 12:32:40 +00:00
Kostya Serebryany
7534a60753
[asan] Respect personality in kernel area detector, patch by Yuri Gribov
...
llvm-svn: 208760
2014-05-14 08:13:11 +00:00
Evgeniy Stepanov
adc3ff9f48
[sanitizer] Move open_memstream test under Linux.
...
llvm-svn: 208755
2014-05-14 07:27:18 +00:00
Greg Fitzgerald
5a1cf70ac3
removed redundant lit variable
...
Thanks Alexey!
llvm-svn: 208747
2014-05-14 01:04:17 +00:00
Greg Fitzgerald
320713ffbe
Add target flags to ubsan tests
...
llvm-svn: 208746
2014-05-14 00:46:01 +00:00
Greg Fitzgerald
1402830dc5
Add %run to tests that used %T/name.exe
...
llvm-svn: 208744
2014-05-14 00:32:15 +00:00
Alexey Samsonov
5716928ae2
[TSan] Build TSan-instrumented version of libcxx and use it in lit tests.
...
TSan can produce false positives in code that uses C++11 threading,
as it doesn't see synchronization inside standard library. See
http://lists.cs.uiuc.edu/pipermail/cfe-dev/2014-February/035408.html
for an example of such case.
We may build custom TSan-instrumented version libcxx to fight with that.
This change adds build rules for libcxx_tsan and integrates it into
testing infrastructure.
llvm-svn: 208737
2014-05-13 22:30:16 +00:00
Alexander Potapenko
4a6cac4382
[libsanitizer] Use internal_fork() to spawn the symbolizer process.
...
This should fix https://code.google.com/p/thread-sanitizer/issues/detail?id=61
llvm-svn: 208707
2014-05-13 16:17:54 +00:00
Evgeniy Stepanov
5680a26b0b
[msan] Better open_memstream support.
...
Move fflush and fclose interceptors to sanitizer_common.
Use a metadata map to keep information about the external locations
that must be updated when the file is written to.
llvm-svn: 208676
2014-05-13 08:36:31 +00:00
Alexey Samsonov
79b8fb5d2c
Mark ptrace test as Linux-specific
...
llvm-svn: 208643
2014-05-13 00:02:18 +00:00
Alexey Samsonov
b51d6081f3
Restrict the set of sanitizers that should run tests from test/sanitizer_common
...
llvm-svn: 208639
2014-05-12 22:48:29 +00:00
Greg Fitzgerald
fb1d83a978
Add %run to new lit test
...
llvm-svn: 208624
2014-05-12 20:17:14 +00:00
Kostya Serebryany
118d469660
[asan] one more attempt to enable lsan by default (PR19521)
...
llvm-svn: 208545
2014-05-12 12:49:48 +00:00
Sergey Matveev
aeb18fc787
[asan] Further fix the test from r208333.
...
Remove a debug print and some copypasta.
llvm-svn: 208535
2014-05-12 10:33:31 +00:00
Kostya Serebryany
d7992fc921
[asan] fix a self deadlock when printing stats; add a relevant test, cleanup that test while at it to remove linux/darwin differences. Fixes http://code.google.com/p/address-sanitizer/issues/detail?id=306
...
llvm-svn: 208525
2014-05-12 08:01:51 +00:00
Duncan P. N. Exon Smith
b6bd2f6cf7
InstrProf: Pacify buildbots after r208460
...
llvm-svn: 208462
2014-05-09 23:47:49 +00:00
Duncan P. N. Exon Smith
238137294f
InstrProf: Test the functions in the runtime
...
Check that the profile runtime works as expected. This tests the
functions that are meant to be available to advanced users.
In particular, check that the `atexit()` hook can be disabled by
defining a custom `__llvm_profile_runtime` variable, that the libc
dependencies are optional, and that the various functions for writing
out files work for basic cases.
llvm-svn: 208460
2014-05-09 23:14:58 +00:00
Alexey Samsonov
0bef819f9f
[Sanitizer] Add the machinery to run the same test under several sanitizers
...
llvm-svn: 208378
2014-05-09 00:28:18 +00:00
Alexey Samsonov
6dd8dfb1c4
[Sanitizer] Move lit config for sanitizer_common unit tests under Unit/ dir for consistency.
...
llvm-svn: 208373
2014-05-08 23:53:02 +00:00
Alexey Samsonov
35744c4753
Fixup for r208066. Properly get values of PTRACE_GETREGSET/PTRACE_SETREGSET.
...
llvm-svn: 208363
2014-05-08 22:11:20 +00:00
Alexey Samsonov
0b9b36623a
Fixup test added in r208333
...
llvm-svn: 208356
2014-05-08 20:21:11 +00:00
Sergey Matveev
76e02e90c5
[ASan] Fix coverage behavior when a PC belongs to an unknown address range.
...
This happens, e.g., when coverage data is collected for a module which is then
dlclose()'d. Currently this causes CovDump() to ignore all PCs that are greater
than the unrecognized PC. In other words, unloading a module causes ASan to
silently ignore any coverage data for modules loaded at higher addresses.
Instead we should just skip the unrecognized PCs.
llvm-svn: 208333
2014-05-08 16:09:54 +00:00
Evgeniy Stepanov
c5e51926dc
[msan] Intercept strxfrm.
...
llvm-svn: 208303
2014-05-08 12:04:01 +00:00
Evgeniy Stepanov
9c20cb1a7c
[msan] Fix potential infinite recursion in a test.
...
If printf is intercepted (it is not atm), REAL(printf) call in the interceptor
would get redirected back to my_lgamma, resulting in infinite recursion.
llvm-svn: 208294
2014-05-08 09:37:36 +00:00
Evgeniy Stepanov
5ee9fd5f45
[asan] Update tests for r208290.
...
sprintf output buffer is now always sanitized.
llvm-svn: 208291
2014-05-08 09:24:53 +00:00
Greg Fitzgerald
dda7f8cfd0
[asan] fix i386 tests broken from r207707
...
llvm-svn: 208240
2014-05-07 19:22:16 +00:00
Evgeniy Stepanov
55590227f8
[sanitizer] Intercept obstack.
...
llvm-svn: 208196
2014-05-07 11:50:56 +00:00
Evgeniy Stepanov
8dd62dc3be
[msan] Fix __msan_check_mem_is_initialized and prettify its output.
...
llvm-svn: 208195
2014-05-07 11:50:14 +00:00
Kostya Serebryany
7a733480c8
[asan] introduce interface function __sanitizer_verify_contiguous_container to verify annotations in vector-like containers
...
llvm-svn: 208092
2014-05-06 14:41:01 +00:00
Evgeniy Stepanov
06475bf752
[msan] Fix print_shadow test.
...
llvm-svn: 208069
2014-05-06 08:15:50 +00:00
Kostya Serebryany
12963b54a8
[asan] disable GetKernelStartAddress as it misbehaves in schroot
...
llvm-svn: 207768
2014-05-01 16:20:23 +00:00
Greg Fitzgerald
b8aae5405b
Add %run to all lit tests
...
llvm-svn: 207709
2014-04-30 21:34:17 +00:00
Greg Fitzgerald
6759fd9fdd
Allow any test to be executed via a %run command.
...
Configure %run with COMPILER_RT_EMULATOR:
$ cmake -DCOMPILER_RT_EMULATOR="qemu-arm -L $SYSROOT"
llvm-svn: 207707
2014-04-30 21:32:30 +00:00
Evgeniy Stepanov
fe250b0014
[msan] Prettify __msan_print_shadow.
...
Makes __msan_print_shadow output much more readable, adds origin info.
llvm-svn: 207622
2014-04-30 09:50:30 +00:00
Kostya Serebryany
cacbac7ba9
[asan] fix a test
...
llvm-svn: 207417
2014-04-28 13:18:59 +00:00
Kostya Serebryany
4f9c31a2fa
[asan] split detect_odr_violation into two: =2 detects all ODR violations, =1 detects only those where the variable sizes are different. BTW, the detector seems to be working well and finding nice bugs. Early adopters are welcome.
...
llvm-svn: 207415
2014-04-28 12:47:58 +00:00
Evgeniy Stepanov
f3d5d119a8
[sanitizer] Intercept a bunch of stdio calls.
...
Add move fopen/freopen interceptors from TSan to common.
llvm-svn: 207224
2014-04-25 13:26:21 +00:00
Kostya Serebryany
e91930a7e6
[asan] implement an experimental detector of ODR violations. Not tested yet outside of a tiny test, may need tuning.
...
llvm-svn: 207210
2014-04-25 08:58:28 +00:00
Dmitry Vyukov
56a18f02ea
tsan: better reports for "read lock of a write locked mutex"
...
llvm-svn: 207209
2014-04-25 08:58:23 +00:00
Dmitry Vyukov
e296164f77
tsan: improve "read unlock of a write locked mutex" report
...
llvm-svn: 207208
2014-04-25 08:21:30 +00:00
Dmitry Vyukov
66dbbbc47b
tsan: fix tests
...
failure:
http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-centos-6.5/builds/3747/steps/test/logs/stdio
llvm-svn: 207207
2014-04-25 08:13:45 +00:00
Dmitry Vyukov
2c87108a42
tsan: better report for bad mutex unlocks
...
+ fixes crashes due to races on symbolizer, see
https://code.google.com/p/thread-sanitizer/issues/detail?id=55
llvm-svn: 207206
2014-04-25 07:55:11 +00:00
Dmitry Vyukov
ea014b787a
tsan: add new test for commit 207204 (forget to add new file)
...
llvm-svn: 207205
2014-04-25 07:49:36 +00:00