Dmitry Vyukov
536551d02d
tasn: do not remember stack traces for sync objects for Go (they are not reported anyway)
...
llvm-svn: 160861
2012-07-27 13:21:33 +00:00
Dmitry Vyukov
e91e9ac2a2
tsan: remove unnecessary and wrong include
...
llvm-svn: 160860
2012-07-27 13:21:01 +00:00
Kostya Serebryany
4c38790f70
[asan] ensure that asan_init is called in str[n]cmp. Bug found by Nick Kralevich (thanks)
...
llvm-svn: 160853
2012-07-27 07:09:49 +00:00
Dmitry Vyukov
65ec6684c2
tsan: make the runtime library name tsan-neutral for Go upstream
...
llvm-svn: 160797
2012-07-26 18:42:51 +00:00
Dmitry Vyukov
55b405ef42
tsan: allow environment to override OnReport() and OverrideFlags()
...
llvm-svn: 160728
2012-07-25 14:30:51 +00:00
Dmitry Vyukov
dfc8e52400
tsan: suport for Go finalizers
...
llvm-svn: 160723
2012-07-25 13:16:35 +00:00
Dmitry Vyukov
d654f06644
tsan: expect that Go symbolizer can return NULLs
...
llvm-svn: 160722
2012-07-25 11:50:37 +00:00
Alexey Samsonov
5062359502
cmake for compiler-rt: add a function to set output dirs for compiler runtimes equal to directory used by Clang driver. Use it for ASan runtime. Also, make sure that ASan unit tests depend on the ASan runtime.
...
llvm-svn: 160721
2012-07-25 11:15:00 +00:00
Kostya Serebryany
bb0ade6daa
[asan] don't return from a never-return function. fix a test that had a chain of bugs instead of just one
...
llvm-svn: 160719
2012-07-25 10:56:09 +00:00
Alexey Samsonov
c145b02607
[ASan] fixup for r160712: provide a default definition for weak __asan_default_options()
...
llvm-svn: 160718
2012-07-25 10:40:57 +00:00
Alexander Potapenko
9bac1cedbc
Make __asan_default_options a weak function that returns a const char*.
...
Users may define it to override the default ASan options.
This function has to be marked with __attribute__((no_address_safety_analysis)), because it is called before ASan is fully initialized.
Add an output test checking the __asan_default_options functionality.
llvm-svn: 160712
2012-07-25 09:18:43 +00:00
Dmitry Vyukov
bcf0b7002b
tsan: align report style with Go internal format
...
llvm-svn: 160672
2012-07-24 12:29:43 +00:00
Alexey Samsonov
65d842ae51
Revert r160669 (except for compile flag updates)
...
llvm-svn: 160671
2012-07-24 12:11:38 +00:00
Dmitry Vyukov
69bee8d8f6
tsan: output goroutine creation stack
...
llvm-svn: 160670
2012-07-24 12:03:47 +00:00
Alexey Samsonov
3397013606
[ASan] hacking cmake build: after generating asan runtime, copy it to the Clang lib directory where Clang driver expects to find it.
...
llvm-svn: 160669
2012-07-24 11:49:55 +00:00
Alexey Samsonov
96b9393f2d
[ASan] Support for cmake build of ASan unittests in 32-bit LLVM build. Currently, to run ASan unit tests both for 32- and 64 bits one has to maintain two distinct LLVM builds. In a bright future, we'd like to use a single build for this
...
llvm-svn: 160666
2012-07-24 08:26:19 +00:00
Alexander Potapenko
51e6488b31
Intercept CFAllocator for each thread in the program.
...
Test that child threads use the ASan allocator, that allocated memory can be passed to another thread and deallocated on it.
This should fix http://code.google.com/p/address-sanitizer/issues/detail?id=81
llvm-svn: 160630
2012-07-23 14:07:58 +00:00
Alexey Samsonov
37d5134f38
[ASan] minor fixes to silence cmake build warnings
...
llvm-svn: 160624
2012-07-23 09:11:58 +00:00
Alexander Potapenko
7f3e84c9fd
For wild addresses in the shadow or shadow gap areas print an error message instead of crashing on a check.
...
Add AddressSanitizer.MemsetWildAddressTest that makes sure a proper error message is printed.
llvm-svn: 160620
2012-07-23 08:22:27 +00:00
Alexey Samsonov
3735faa108
[ASan] subtract one from PCs in ASan error reports (as they originally contain return addresses). Make output tests stricter.
...
llvm-svn: 160508
2012-07-19 15:07:26 +00:00
Kostya Serebryany
7a32f8dcb8
[tsan] fix lint
...
llvm-svn: 160504
2012-07-19 12:22:04 +00:00
Kostya Serebryany
a415df6539
[tsan] minor fixes in tsan allocator and its testlib. Now runs fine with chrome
...
llvm-svn: 160503
2012-07-19 12:15:33 +00:00
Alexander Potapenko
628b349b17
Suppress the stderr output from atos.
...
llvm-svn: 160502
2012-07-19 12:01:07 +00:00
Alexey Samsonov
7acdc1738f
[Sanitizer] When obtaining the data for loaded modules, add address ranges of loadable segments only. Looks like address range of PT_TLS segment may intersect with loadable segments of other modules.
...
llvm-svn: 160498
2012-07-19 07:51:20 +00:00
Kostya Serebryany
ab34919413
[tsan] minor enhancements in the new tsan allocator and a test malloc replacement library that can be linked to any program to replace malloc (tested on spec2006)
...
llvm-svn: 160436
2012-07-18 16:04:55 +00:00
Alexey Samsonov
c6d97c0ad1
[TSan] fix confusing error message in CheckFailed
...
llvm-svn: 160435
2012-07-18 14:37:22 +00:00
Alexey Samsonov
4dbfad627e
[Sanitizer] add missing unit test for flag parsing (forgot to run svn add before)
...
llvm-svn: 160428
2012-07-18 06:29:18 +00:00
Alexey Samsonov
93ca829c2d
[TSan] cleanup header comments
...
llvm-svn: 160359
2012-07-17 09:39:59 +00:00
Kostya Serebryany
78713bc574
[asan] get rid of the last operator new call in asan rtl
...
llvm-svn: 160347
2012-07-17 07:20:13 +00:00
Dmitry Vyukov
f2bc464f37
tsan: add platform suffix to Go runtime library
...
llvm-svn: 160304
2012-07-16 18:25:43 +00:00
Dmitry Vyukov
3abd096370
tsan: treat malloc() as memory access in Go
...
llvm-svn: 160289
2012-07-16 16:55:01 +00:00
Dmitry Vyukov
5bfac97ff9
tsan: use dynamic shadow stack for Go
...
llvm-svn: 160288
2012-07-16 16:44:47 +00:00
Dmitry Vyukov
dc36d69b6a
tsan: increase number of dead threads for Go
...
llvm-svn: 160283
2012-07-16 16:03:16 +00:00
Dmitry Vyukov
9270eaf1f2
tsan: Go runtime: support goroutine end event
...
llvm-svn: 160282
2012-07-16 16:01:08 +00:00
Dmitry Vyukov
5e5e36712b
tsan: fix build
...
llvm-svn: 160267
2012-07-16 13:25:47 +00:00
Dmitry Vyukov
c40c00767c
tsan: port Go runtime to Darwin
...
llvm-svn: 160266
2012-07-16 13:02:40 +00:00
Alexey Samsonov
d77fbba74a
[Sanitizer] implement straightforward nlogn sorting, as qsort() may call malloc, which leads to deadlock in ASan allocator
...
llvm-svn: 160262
2012-07-16 11:27:17 +00:00
Dmitry Vyukov
263efd8f05
tsan: allow to pass CFLAGS to Go runtime build script
...
llvm-svn: 160259
2012-07-16 10:36:39 +00:00
Dmitry Vyukov
2dac24a42b
tsan: add missing test for Go runtime
...
llvm-svn: 160258
2012-07-16 10:34:57 +00:00
Kostya Serebryany
38f318bf20
[tsan] use internal_strnlen in strncpy interceptor (the bug found while booting chromium)
...
llvm-svn: 160171
2012-07-13 13:04:43 +00:00
Nick Kledzik
35293305b7
<rdar://problem/11668446> Add .subsections_via_symbols to Darwin assembly files
...
llvm-svn: 160062
2012-07-11 19:21:39 +00:00
Alexey Samsonov
2d4bd13eb6
[Sanitizer] fix CMake build
...
llvm-svn: 159988
2012-07-10 09:17:06 +00:00
Alexey Samsonov
9f666ea6ca
[ASan] move flags description to separate header, add comments about them.
...
llvm-svn: 159985
2012-07-10 07:41:27 +00:00
Alexey Samsonov
2467ca5010
[ASan] cleanup: remove dead flag
...
llvm-svn: 159934
2012-07-09 15:11:28 +00:00
Alexey Samsonov
34efb8e9b9
[ASan] Use common flags parsing machinery.
...
llvm-svn: 159933
2012-07-09 14:36:04 +00:00
Alexey Samsonov
2c94cd6e3d
[Sanitizer] move flag parsing routines (and unit tests) from tsan runtime to common runtime.
...
llvm-svn: 159928
2012-07-09 13:21:39 +00:00
Alexander Potapenko
b4e9fd297c
Suppress a lint warning.
...
llvm-svn: 159915
2012-07-08 15:00:06 +00:00
Dmitry Vyukov
239ae7186b
tsan: Go language support fixes
...
llvm-svn: 159856
2012-07-06 20:23:59 +00:00
Dmitry Vyukov
e0d31e9170
tsan: Go lang: symbolize stack traces
...
llvm-svn: 159827
2012-07-06 14:54:25 +00:00
Kostya Serebryany
739b0de5b1
[tsan] start using AllocatorCache in CombinedAllocator
...
llvm-svn: 159825
2012-07-06 14:32:00 +00:00