Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | [asan] Modify ASan metadata atomically. | Sergey Matveev | 2013-05-20 | 1 | -3/+5 | |
| | | | | | | We need this to avoid races when ASan and LSan are used together. llvm-svn: 182252 | |||||
* | [ASan] Remove an unused ChunkBase field | Timur Iskhodzhanov | 2013-05-20 | 1 | -5/+3 | |
| | | | | | | Also fix wrong alignment maths and an outdated comment llvm-svn: 182238 | |||||
* | [sanitizer] factor out ByteMap from SizeClassAllocator32 so that it can be ↵ | Kostya Serebryany | 2013-05-20 | 1 | -1/+5 | |
| | | | | | | later replaced with a more memory-efficient implementation on 64-bit. llvm-svn: 182234 | |||||
* | Replace CHECK(a == b); with CHECK_EQ(a, b); throughout asan_allocator2.cc | Timur Iskhodzhanov | 2013-05-18 | 1 | -3/+3 | |
| | | | | llvm-svn: 182198 | |||||
* | [asan] fix powerpc build and one test; fix lint | Kostya Serebryany | 2013-05-15 | 1 | -1/+2 | |
| | | | | llvm-svn: 181881 | |||||
* | [asan] Common flags in ASan. | Sergey Matveev | 2013-05-06 | 1 | -0/+1 | |
| | | | | | | | Some flags that are common to ASan/MSan/TSan/LSan have been moved to sanitizer_common. llvm-svn: 181193 | |||||
* | [asan] nuke the old unused allocator code | Kostya Serebryany | 2013-04-04 | 1 | -4/+0 | |
| | | | | llvm-svn: 178758 | |||||
* | [asan] fill first 4K of malloc-ed memory with garbage, implement flags ↵ | Kostya Serebryany | 2013-04-04 | 1 | -11/+16 | |
| | | | | | | max_malloc_fill_size and malloc_fill_byte llvm-svn: 178757 | |||||
* | [ASan] Speed-up initialization-order checking: create and use fast versions ↵ | Alexey Samsonov | 2013-03-28 | 1 | -0/+1 | |
| | | | | | | of PoisonShadow functions, store copies of __asan_global descriptors in a vector instead of list of pointers. This gives 3x speedup on both benchmarks and real binaries with lots of globals. llvm-svn: 178239 | |||||
* | Revert 177745 as it was incorrect | Timur Iskhodzhanov | 2013-03-22 | 1 | -2/+1 | |
| | | | | llvm-svn: 177746 | |||||
* | Band-aid fix for the Windows build caused by r177710. Long-term, ↵ | Timur Iskhodzhanov | 2013-03-22 | 1 | -1/+2 | |
| | | | | | | atomic_compare_exchange_strong should be a template on Windows too... llvm-svn: 177745 | |||||
* | [ASan] Fix an error on invalid deallocation in ASan allocator. When ASan ↵ | Alexey Samsonov | 2013-03-22 | 1 | -8/+10 | |
| | | | | | | 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 | |||||
* | [ASan] Switch ASan to generic ThreadRegistry from sanitizer_common. Delete ↵ | Alexey Samsonov | 2013-03-21 | 1 | -1/+0 | |
| | | | | | | ASan-specific AsanThreadRegistry. llvm-svn: 177634 | |||||
* | [ASan] Move malloc stats collection away from AsanThreadRegistry class. | Alexey Samsonov | 2013-03-20 | 1 | -6/+6 | |
| | | | | llvm-svn: 177508 | |||||
* | [ASan] Move GetCurrentThread/SetCurrentThread from AsanThreadRegistry class ↵ | Alexey Samsonov | 2013-03-20 | 1 | -2/+2 | |
| | | | | | | into plain functions: they don't actually use registry llvm-svn: 177501 | |||||
* | [asan] use 4Tb of address space for the asan allocator instead of 1Tb. This ↵ | Kostya Serebryany | 2013-03-12 | 1 | -1/+1 | |
| | | | | | | increases the memory available for a single size class from 16Gb to 64Gb. The total VM footprint becomes 20Tb llvm-svn: 176857 | |||||
* | [asan] if calloc returns a freshly-mmaped memory, don't clear it with ↵ | Kostya Serebryany | 2013-02-27 | 1 | -1/+3 | |
| | | | | | | memset. Speeds up calloc-intensive code llvm-svn: 176185 | |||||
* | [asan] a bit stricter lint for CHECK vs CHECK_XX (these CHECK_XX really help ↵ | Kostya Serebryany | 2013-02-26 | 1 | -1/+1 | |
| | | | | | | debugging!) llvm-svn: 176085 | |||||
* | [ASan] Switch Windows to allocator v2, also fixing some build errors | Timur Iskhodzhanov | 2013-02-08 | 1 | -1/+1 | |
| | | | | llvm-svn: 174707 | |||||
* | [ASan] Implement asan_mz_size(), asan_mz_force_lock() and ↵ | Alexander Potapenko | 2013-02-07 | 1 | -4/+5 | |
| | | | | | | | | asan_mz_force_unlock() for allocator2. Switch to allocator2 on Darwin. llvm-svn: 174603 | |||||
* | [asan] Fix nonsensical reports of partial right OOB. | Evgeniy Stepanov | 2013-02-05 | 1 | -2/+2 | |
| | | | | | | | | | | In case of partial right OOB, ASan was reporting X is located 0 bytes to the right of [A, B) where X was actually inside [A, B). With this change, ASan will report B as the error address in such case. llvm-svn: 174373 | |||||
* | [ASan] Split ASan interface header into private and public parts. Add a test ↵ | Alexey Samsonov | 2013-01-31 | 1 | -1/+0 | |
| | | | | | | that makes sure users can include interface header llvm-svn: 174058 | |||||
* | [ASan] fix deallocation hook in allocator2: according to specification, ↵ | Alexey Samsonov | 2013-01-29 | 1 | -2/+1 | |
| | | | | | | dealloc hook should be called before deallocating memory llvm-svn: 173778 | |||||
* | [ASan] Do allocate memory even for zero-size allocation requests. Explain ↵ | Alexey Samsonov | 2013-01-29 | 1 | -10/+10 | |
| | | | | | | why we have to do this in comments. llvm-svn: 173776 | |||||
* | [ASan] fix a bug in allocator-v2 which could lead to SEGV on ↵ | Alexey Samsonov | 2013-01-28 | 1 | -1/+1 | |
| | | | | | | realloc(malloc(0), 4) llvm-svn: 173681 | |||||
* | [asan] fix a crash in asan stats printing (initialize the allocator in ↵ | Kostya Serebryany | 2013-01-28 | 1 | -6/+3 | |
| | | | | | | __asan_init) llvm-svn: 173676 | |||||
* | [sanitizer] fix calloc overflow in asan/tsan/msan | Kostya Serebryany | 2013-01-25 | 1 | -0/+1 | |
| | | | | llvm-svn: 173441 | |||||
* | [asan] initialize kHighMemEnd at startup (instead of at compile time) to ↵ | Kostya Serebryany | 2013-01-23 | 1 | -0/+4 | |
| | | | | | | simplify further changes for various address space layouts. Fix asan_allocator2 for PowerPC (tested on 44-bit address space) llvm-svn: 173260 | |||||
* | [ASan] fix __asan_get_ownership(p) and __asan_get_allocated_size(p) for the ↵ | Alexey Samsonov | 2013-01-17 | 1 | -4/+6 | |
| | | | | | | p = malloc(0) llvm-svn: 172717 | |||||
* | [asan] asan_allocator2: fix the memalign handling (clear the first word of ↵ | Kostya Serebryany | 2013-01-16 | 1 | -0/+2 | |
| | | | | | | allocated chunk in case there is an old memalign magic) llvm-svn: 172603 | |||||
* | asan: weaken memory ordering, it's expensive in current implementation | Dmitry Vyukov | 2013-01-11 | 1 | -1/+1 | |
| | | | | llvm-svn: 172210 | |||||
* | [asan] fid asan_allocator2 build | Kostya Serebryany | 2013-01-11 | 1 | -1/+1 | |
| | | | | llvm-svn: 172194 | |||||
* | asan: always pass allocator cache to Allocate() | Dmitry Vyukov | 2013-01-11 | 1 | -2/+9 | |
| | | | | llvm-svn: 172193 | |||||
* | asan: faster quarantine | Dmitry Vyukov | 2013-01-11 | 1 | -5/+7 | |
| | | | | llvm-svn: 172192 | |||||
* | asan: Refactor asan memory quarantine. | Dmitry Vyukov | 2013-01-11 | 1 | -61/+42 | |
| | | | | llvm-svn: 172183 | |||||
* | [asan] asan_allocator2: do less work under the quarantine lock; make the ↵ | Kostya Serebryany | 2013-01-10 | 1 | -11/+11 | |
| | | | | | | strcasecmp test more resistant to the contents of unaddressable memory llvm-svn: 172048 | |||||
* | [sanitizer] add statistics to the allocator; fix lint | Kostya Serebryany | 2012-12-27 | 1 | -0/+4 | |
| | | | | llvm-svn: 171161 | |||||
* | [asan/tsan] when unmapping a chunk of user memory, apply ↵ | Kostya Serebryany | 2012-12-27 | 1 | -1/+8 | |
| | | | | | | madvise(MADV_DONTNEED) to the corresponding chunk of shadow memory. Also update sanitizer_allocator64_testlib.cc llvm-svn: 171144 | |||||
* | [asan] asan_allocator2: do not align the requested size to the redzone size ↵ | Kostya Serebryany | 2012-12-26 | 1 | -6/+10 | |
| | | | | | | (saves a bit more memory) llvm-svn: 171111 | |||||
* | [asan] asan_allocator2: implement adaptive redzones. Now with ↵ | Kostya Serebryany | 2012-12-26 | 1 | -30/+79 | |
| | | | | | | asan_allocator2 allocations <= 48 bytes have 16 byte redzone, allocations of 48-96 bytes -- have 32 bytes redzone, etc (max redzone is 2048). If ASAN_OPTIONS=redzone=n is set, it changes the minimal redzone size llvm-svn: 171107 | |||||
* | [asan] asan_allocator2: by default use the StackDepot to store the stack ↵ | Kostya Serebryany | 2012-12-26 | 1 | -9/+35 | |
| | | | | | | traces instead of storing them in the redzones llvm-svn: 171099 | |||||
* | [asan] asan_allocator2: store the user requested size in just 32 bits ↵ | Kostya Serebryany | 2012-12-26 | 1 | -37/+45 | |
| | | | | | | (larger sizes use metadata). This allows to put one more 32-bit field into the chunk header llvm-svn: 171089 | |||||
* | [asan] add a test for right OOB with special large sizes. Fix this test in ↵ | Kostya Serebryany | 2012-12-25 | 1 | -0/+4 | |
| | | | | | | asan_allocator2. More test tweaking for allocator2 llvm-svn: 171058 | |||||
* | [asan] asan_allocator2 fix two asserts that happen on full chrome: a) ↵ | Kostya Serebryany | 2012-12-21 | 1 | -7/+9 | |
| | | | | | | memalign called with 0 size and large alignment and b) malloc called after TSD has been destructed llvm-svn: 170900 | |||||
* | [asan] asan_allocator2: better memory stats | Kostya Serebryany | 2012-12-21 | 1 | -2/+13 | |
| | | | | llvm-svn: 170888 | |||||
* | [asan] add a flag alloc_dealloc_mismatch (off by default for now) which ↵ | Kostya Serebryany | 2012-12-21 | 1 | -15/+25 | |
| | | | | | | finds malloc/delete, new/free, new/delete[], etc mismatches llvm-svn: 170869 | |||||
* | [asan] asan_allocator2: implement memalign | Kostya Serebryany | 2012-12-20 | 1 | -4/+27 | |
| | | | | llvm-svn: 170697 | |||||
* | [asan] add a flag poison_heap to allow better allocator benchmarking, ↵ | Kostya Serebryany | 2012-12-20 | 1 | -1/+1 | |
| | | | | | | implemenet malloc_stats() on Linux llvm-svn: 170685 | |||||
* | [asan] asan_allocator2: make all remaining tests pass. | Kostya Serebryany | 2012-12-20 | 1 | -11/+27 | |
| | | | | llvm-svn: 170680 | |||||
* | [asan] asan_allocator2: add mmap/munmap stats | Kostya Serebryany | 2012-12-19 | 1 | -0/+13 | |
| | | | | llvm-svn: 170548 |