| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
| |
Test fails in bootstrap build.
llvm-svn: 201411
|
|
|
|
|
|
|
|
| |
These are runtime support functions for inline assembly instrumentation.
Patch by Yuri Gorshenin.
llvm-svn: 201402
|
|
|
|
| |
llvm-svn: 196904
|
|
|
|
|
|
| |
assumption that the left stack redzone is >= 32 bytes (PR18195)
llvm-svn: 196900
|
|
|
|
|
|
| |
checks to 64-bit
llvm-svn: 196576
|
|
|
|
|
|
| |
stack buffer overflows in another test
llvm-svn: 196375
|
|
|
|
| |
llvm-svn: 196374
|
|
|
|
|
|
| |
stack buffer overflows in another test
llvm-svn: 196373
|
|
|
|
|
|
| |
is set
llvm-svn: 196097
|
|
|
|
|
|
|
| |
The same as with MSan, this test behavior depends on ASAN_OPTIONS, and we've
got a lit_test that covers this.
llvm-svn: 192777
|
|
|
|
|
|
|
| |
(1) instrumented, i.e. compiled and linked with -fsanitize=address
(2) not instrumented, compiled w/o -fsanitize=address and linked with ASan runtime statically.
llvm-svn: 190788
|
|
|
|
|
|
| |
ATTRIBUTE_NO_SANITIZE_ADDRESS
llvm-svn: 190136
|
|
|
|
|
|
| |
(controlled by the allocator_may_return_null flag)
llvm-svn: 190127
|
|
|
|
| |
llvm-svn: 186577
|
|
|
|
| |
llvm-svn: 183411
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
With this change, the user may safely call __asan_get_ownership()
from malloc/free hooks and assume it would return "true". If there is a
realloc/free race, free hook might be called twice, but I think it's acceptable,
as it's a data race and would later be reported anyway.
This change also fixes a bug when failing realloc incorrectly marked the
original memory as "quarantinned".
Reviewers: timurrrr, kcc, samsonov
Reviewed By: samsonov
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D913
llvm-svn: 183220
|
|
|
|
|
|
| |
kill). Also, disable swapcontext_test on non-x86. Fix lint
llvm-svn: 182456
|
|
|
|
| |
llvm-svn: 182353
|
|
|
|
|
|
| |
See https://code.google.com/p/address-sanitizer/issues/detail?id=187 for the details
llvm-svn: 182255
|
|
|
|
| |
llvm-svn: 181991
|
|
|
|
| |
llvm-svn: 181890
|
|
|
|
| |
llvm-svn: 181881
|
|
|
|
|
|
| |
See https://code.google.com/p/address-sanitizer/issues/detail?id=131.
llvm-svn: 180093
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before: the function name was stored by the compiler as a constant string
and the run-time was printing it.
Now: the PC is stored instead and the run-time prints the full symbolized frame.
This adds a couple of instructions into every function with non-empty stack frame,
but also reduces the binary size because we store less strings (I saw 2% size reduction).
This change bumps the asan ABI version to v3.
compiler-rt part, llvm part will follow.
Example of report (now):
==31711==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7fffa77cf1c5 at pc 0x41feb0 bp 0x7fffa77cefb0 sp 0x7fffa77cefa8
READ of size 1 at 0x7fffa77cf1c5 thread T0
#0 0x41feaf in Frame0(int, char*, char*, char*) stack-oob-frames.cc:20
#1 0x41f7ff in Frame1(int, char*, char*) stack-oob-frames.cc:24
#2 0x41f477 in Frame2(int, char*) stack-oob-frames.cc:28
#3 0x41f194 in Frame3(int) stack-oob-frames.cc:32
#4 0x41eee0 in main stack-oob-frames.cc:38
#5 0x7f0c5566f76c (/lib/x86_64-linux-gnu/libc.so.6+0x2176c)
#6 0x41eb1c (/usr/local/google/kcc/llvm_cmake/a.out+0x41eb1c)
Address 0x7fffa77cf1c5 is located in stack of thread T0 at offset 293 in frame
#0 0x41f87f in Frame0(int, char*, char*, char*) stack-oob-frames.cc:12 <<<<<<<<<<<<<< this is new
This frame has 6 object(s):
[32, 36) 'frame.addr'
[96, 104) 'a.addr'
[160, 168) 'b.addr'
[224, 232) 'c.addr'
[288, 292) 's'
[352, 360) 'd'
llvm-svn: 177723
|
|
|
|
|
|
| |
checks if memory freed by user was indeed previously allocated, it first does an atomic write to presumed location of chunk header. This is wrong, as if the free is invalid, we may overwrite some valuable data (like other fields of the chunk header). Fix this by using atomic_compare_exchange instead.
llvm-svn: 177710
|
|
|
|
| |
llvm-svn: 177263
|
|
|
|
|
|
| |
ASAN_LOW_MEMORY macro in tests, slightly reduce test memory usage (all to make 32-bit runs consume less RAM)
llvm-svn: 177069
|
|
|
|
|
|
| |
New allocator has 1.5x memory overhead of the old one.
llvm-svn: 176340
|
|
|
|
| |
llvm-svn: 176264
|
|
|
|
|
|
| |
more strict checking in memcmp
llvm-svn: 176078
|
|
|
|
| |
llvm-svn: 175655
|
|
|
|
|
|
|
|
| |
declarations to asan_intercepted_functions.h
Now that we have only one dependency on asan_intercepted_functions.h, we can unite that code with the interceptors declarations in asan_interceptors.cc and get rid of asan_intercepted_functions.h
llvm-svn: 175631
|
|
|
|
| |
llvm-svn: 175514
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch makes asan instrument memory accesses with unusual sizes (e.g. 5 bytes or 10 bytes), e.g. long double or
packed structures.
Instrumentation is done with two 1-byte checks
(first and last bytes) and if the error is found
__asan_report_load_n(addr, real_size) or
__asan_report_store_n(addr, real_size)
is called.
asan-rt part
Also fix lint.
llvm-svn: 175508
|
|
|
|
|
|
| |
Enable AddressSanitizer.AllocDeallocMismatch tests.
llvm-svn: 174628
|
|
|
|
| |
llvm-svn: 174188
|
|
|
|
| |
llvm-svn: 173795
|
|
|
|
|
|
| |
why we have to do this in comments.
llvm-svn: 173776
|
|
|
|
|
|
| |
realloc(malloc(0), 4)
llvm-svn: 173681
|
|
|
|
| |
llvm-svn: 173251
|
|
|
|
| |
llvm-svn: 173131
|
|
|
|
| |
llvm-svn: 173130
|
|
|
|
|
|
| |
building with a debug clang, which takes a couple of minutes on this large file with templates). More splits to follow
llvm-svn: 173129
|
|
|
|
| |
llvm-svn: 173049
|
|
|
|
| |
llvm-svn: 173048
|
|
|
|
| |
llvm-svn: 172800
|
|
|
|
|
|
| |
warning on Mac.
llvm-svn: 172791
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The r172719 patch broke the build on Mac, the others depended on it.
compiler-rt/lib/asan/asan_interceptors.cc:78:13: error: unused function
'SetThreadName' [-Werror,-Wunused-function]
static void SetThreadName(const char *name) {
Orignal headlines:
[asan] attempting to fix the Mac build
[asan] restructure read/pread/pread64 tests
[sanitizer] move write/pwrite/pwrite64 interceptors to common
[msan] start using common interceptors in msan
[tsan] move prctl interceptor from asan to common_interceptors thus enabling it for tsan too
llvm-svn: 172763
|
|
|
|
| |
llvm-svn: 172723
|
|
|
|
|
|
|
|
|
| |
Move my_rand() to the common header.
This lets us avoid the use of rand_r in sanitizer_common tests.
There is no rand_r on Android.
llvm-svn: 172421
|