summaryrefslogtreecommitdiffstats
path: root/compiler-rt/lib/asan
Commit message (Collapse)AuthorAgeFilesLines
* Remove unused variables, as suggested by @mcgov.Alexandre Ganea2019-11-041-3/+0
| | | | Fixes warning: unused variable 'XXX' [-Wunused-const-variable]
* [asan] Fix lint failure in asan_interface.hEvgenii Stepanov2019-10-311-1/+2
|
* [asan] Provide an interface to update an allocation stack trace.Evgenii Stepanov2019-10-313-0/+18
| | | | | | | | | | | | | | Summary: Sometimes an allocation stack trace is not very informative. Provide a way to replace it with a stack trace of the user's choice. Reviewers: pcc, kcc Subscribers: #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D69208
* [sanitizer_common] Create max_allocation_size_mb flag.Matt Morehouse2019-10-301-3/+10
| | | | | | | | | | | | | | | | | Summary: The flag allows the user to specify a maximum allocation size that the sanitizers will honor. Any larger allocations will return nullptr or crash depending on allocator_may_return_null. Reviewers: kcc, eugenis Reviewed By: kcc, eugenis Subscribers: #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D69576
* Reland "[ASan] Do not misrepresent high value address dereferences as null ↵Julian Lettner2019-10-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | dereferences" Updated: Removed offending TODO comment. Dereferences with addresses above the 48-bit hardware addressable range produce "invalid instruction" (instead of "invalid access") hardware exceptions (there is no hardware address decoding logic for those bits), and the address provided by this exception is the address of the instruction (not the faulting address). The kernel maps the "invalid instruction" to SEGV, but fails to provide the real fault address. Because of this ASan lies and says that those cases are null dereferences. This downgrades the severity of a found bug in terms of security. In the ASan signal handler, we can not provide the real faulting address, but at least we can try not to lie. rdar://50366151 Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D68676 > llvm-svn: 374265 llvm-svn: 374384
* Revert "[ASan] Do not misrepresent high value address dereferences as null ↵Russell Gallop2019-10-101-2/+1
| | | | | | | | | | dereferences" As it was breaking bots running sanitizer lint check This reverts r374265 (git b577efe4567f1f6a711ad36e1d17280dd1c4f009) llvm-svn: 374308
* [ASan] Do not misrepresent high value address dereferences as null dereferencesJulian Lettner2019-10-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | Dereferences with addresses above the 48-bit hardware addressable range produce "invalid instruction" (instead of "invalid access") hardware exceptions (there is no hardware address decoding logic for those bits), and the address provided by this exception is the address of the instruction (not the faulting address). The kernel maps the "invalid instruction" to SEGV, but fails to provide the real fault address. Because of this ASan lies and says that those cases are null dereferences. This downgrades the severity of a found bug in terms of security. In the ASan signal handler, we can not provide the real faulting address, but at least we can try not to lie. rdar://50366151 Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D68676 llvm-svn: 374265
* [compiler-rt] Use GetNextInstructionPc in signal handlersVitaly Buka2019-10-021-1/+2
| | | | | | | | | | | | | | | | | | Summary: All other stack trace callers assume that PC contains return address. HWAsan already use GetNextInstructionPc in similar code. PR43339 Reviewers: eugenis, kcc, jfb Subscribers: dexonsmith, dberris, #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D68313 llvm-svn: 373529
* [compiler-rt] Fix lint check failure on commentsJinsong Ji2019-09-221-1/+2
| | | | | | | | | This fixes buildbot failures for https://reviews.llvm.org/rL372459. (at least on PowerPC/Z ) The fix is generated by running clang-format on the error lines only. llvm-svn: 372511
* Add __lsan::ScopedInterceptorDisabler for strerror(3)Kamil Rytarowski2019-09-211-0/+5
| | | | | | | | | | | | | | | | | | | | Summary: strerror(3) on NetBSD uses internally TSD with a destructor that is never fired for exit(3). It's correctly called for pthread_exit(3) scenarios. This is a case when a leak on exit(3) is expected, unavoidable and harmless. Reviewers: joerg, vitalybuka, dvyukov, mgorny Reviewed By: vitalybuka Subscribers: dmgreen, kristof.beyls, jfb, llvm-commits, #sanitizers Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D67337 llvm-svn: 372461
* Stop tracking atexit/__cxa_atexit/pthread_atfork allocations in LSan/NetBSDKamil Rytarowski2019-09-212-1/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: The atexit(3) and __cxa_atexit() calls allocate internally memory and free on exit, after executing all callback. This causes false positives as DoLeakCheck() is called from the atexit handler. In the LSan/ASan tests there are strict checks triggering false positives here. Intercept all atexit(3) and __cxa_atexit() calls and disable LSan when calling the real functions. Stop tracing allocations in pthread_atfork(3) funtions, as there are performed internal allocations that are not freed for the time of running StopTheWorld() code. This avoids false-positives. The same changes have to be replicated in the ASan and LSan runtime. Non-NetBSD OSs are not tested and this code is restricted to NetBSD only. Reviewers: dvyukov, joerg, mgorny, vitalybuka, eugenis Reviewed By: vitalybuka Subscribers: jfb, llvm-commits, #sanitizers Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D67331 llvm-svn: 372459
* Remove asan test for strncat(x, y, 0)David Bolvansky2019-09-171-3/+1
| | | | llvm-svn: 372143
* [ASAN] Adjust asan tests due to new optimizationsDavid Bolvansky2019-09-171-1/+1
| | | | llvm-svn: 372141
* [compiler-rt] Remove some cpplint filtersVitaly Buka2019-09-125-10/+16
| | | | llvm-svn: 371704
* [compiler-rt] Better lint output for .inc filesVitaly Buka2019-09-121-6/+7
| | | | llvm-svn: 371702
* Remove NOLINTs from compiler-rtVitaly Buka2019-09-1119-74/+71
| | | | llvm-svn: 371687
* Update compiler-rt cpplint.pyVitaly Buka2019-09-112-5/+5
| | | | | | https://github.com/cpplint/cpplint/commit/adb3500107f409ac5491188ae652ac3f4d03d9d3 llvm-svn: 371675
* [asan_symbolize] Fix broken pipe handling for python 2.7Alexander Richardson2019-08-271-3/+9
| | | | | | | | I D65322 I added a check for BrokenPipeError. However, python 2.7 doesn't have BrokenPipeError. To be python 2.7 and 3 compatible we need to catch IOError instead and check for errno == errno.EPIPE. llvm-svn: 370025
* [Sanitizer] Using huge page on FreeBSD for shadow mappingDavid Carlier2019-08-271-2/+1
| | | | | | | | | | | | | - Unless explicit configuration, using FreeBSD super pages feature for shadow mapping. - asan only for now. Reviewers: dim, emaste, vitalybuka Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D65851 llvm-svn: 370008
* [asan_symbolize] Attempt to fix build-bot failure after latest changeAlexander Richardson2019-08-261-0/+4
| | | | llvm-svn: 369929
* [asan_symbolize] Avoid blocking when llvm-symbolizer is installed as addr2lineAlexander Richardson2019-08-261-3/+25
| | | | | | | | | | | | | | | | | | | | | | Summary: Currently, llvm-symbolizer will print -1 when presented with -1 and not print a second line. In that case we will block for ever trying to read the file name. This also happens for non-existent files, in which case GNU addr2line exits immediate, but llvm-symbolizer does not (see https://llvm.org/PR42754). While touching these lines, I also added some more debug logging to help diagnose this and potential future issues. Reviewers: kcc, eugenis, glider, samsonov Reviewed By: eugenis Subscribers: kubamracek, #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D65322 llvm-svn: 369924
* [Sanitizer] checks ASLR on FreeBSDDavid Carlier2019-08-221-1/+1
| | | | | | | | | | | | - Especially MemorySanitizer fails if those sysctl configs are enabled. Reviewers: vitalybuka, emaste, dim Reviewed By: dim Differential Revision: https://reviews.llvm.org/D66582 llvm-svn: 369708
* Revert r369472 and r369441Vitaly Buka2019-08-214-71/+34
| | | | | | check-sanitizer does not work on Linux llvm-svn: 369495
* [AArch64][asan] fix typo in AsanStats::PrintSebastian Pop2019-08-201-1/+1
| | | | | | | | | This created an infinite loop that timed out several build bots while executing the test in compiler-rt/test/asan/TestCases/atexit_stats.cpp Differential Revision: https://reviews.llvm.org/D60243 llvm-svn: 369472
* [AArch64] Speed-up leak and address sanitizers on AArch64 for 48-bit VMASebastian Pop2019-08-204-34/+71
| | | | | | | | | | | | | | | | | | This patch fixes https://github.com/google/sanitizers/issues/703 On a Graviton-A1 aarch64 machine with 48-bit VMA, the time spent in LSan and ASan reduced from 2.5s to 0.01s when running clang -fsanitize=leak compiler-rt/test/lsan/TestCases/sanity_check_pure_c.c && time ./a.out clang -fsanitize=address compiler-rt/test/lsan/TestCases/sanity_check_pure_c.c && time ./a.out With this patch, LSan and ASan create both the 32 and 64 allocators and select at run time between the two allocators following a global variable that is initialized at init time to whether the allocator64 can be used in the virtual address space. Differential Revision: https://reviews.llvm.org/D60243 llvm-svn: 369441
* [asan_symbolize] Fix bug where the frame counter was not incremented.Dan Liew2019-08-121-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This bug occurred when a plug-in requested that a binary not be symbolized while the script is trying to symbolize a stack frame. In this case `self.frame_no` would not be incremented. This would cause subsequent stack frames that are symbolized to be incorrectly numbered. To fix this `get_symbolized_lines()` has been modified to take an argument that indicates whether the stack frame counter should incremented. In `process_line_posix()` `get_symbolized_lines(None, ...)` is now used in in the case where we don't want to symbolize a line so that we can keep the frame counter increment in a single function. A test case is included. The test uses a dummy plugin that always asks `asan_symbolize.py` script to not symbolize the first binary that the script asks about. Prior to the patch this would cause the output to script to look something like ``` #0 0x0 #0 0x0 in do_access #1 0x0 in main ``` This is the second attempt at landing this patch. The first (r368373) failed due to failing some android bots and so was reverted in r368472. The new test is now disabled for Android. It turns out that the patch also fails for iOS too so it is also disabled for that family of platforms too. rdar://problem/49476995 Reviewers: kubamracek, yln, samsonov, dvyukov, vitalybuka Subscribers: #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D65495 llvm-svn: 368603
* Revert "[asan_symbolize] Fix bug where the frame counter was not incremented."Mitch Phillips2019-08-091-9/+4
| | | | | | | | | This reverts commit 52a36fae2a3f8560a5be690a67304db5edafc3fe. This commit broke the sanitizer_android buildbot. See comments at https://reviews.llvm.org/rL368373 for more details. llvm-svn: 368472
* [asan_symbolize] Fix bug where the frame counter was not incremented.Dan Liew2019-08-091-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This bug occurred when a plug-in requested that a binary not be symbolized while the script is trying to symbolize a stack frame. In this case `self.frame_no` would not be incremented. This would cause subsequent stack frames that are symbolized to be incorrectly numbered. To fix this `get_symbolized_lines()` has been modified to take an argument that indicates whether the stack frame counter should incremented. In `process_line_posix()` `get_symbolized_lines(None, ...)` is now used in in the case where we don't want to symbolize a line so that we can keep the frame counter increment in a single function. A test case is included. The test uses a dummy plugin that always asks `asan_symbolize.py` script to not symbolize the first binary that the script asks about. Prior to the patch this would cause the output to script to look something like ``` #0 0x0 #0 0x0 in do_access #1 0x0 in main ``` rdar://problem/49476995 Reviewers: kubamracek, yln, samsonov, dvyukov, vitalybuka Subscribers: #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D65495 llvm-svn: 368373
* Restrict the NetBSD ASan TSD fallback to !ASAN_DYNAMICKamil Rytarowski2019-08-071-2/+2
| | | | | | | | | | The fallback to the alternative implementation of TSD with TLS is only needed for the static version of ASan for NetBSD. The same code cannot be reused for the dynamic version of ASan as TLS breaks and TSD code works. llvm-svn: 368219
* [Sanitizer] Linux refactor shadow huge page mode handlingDavid Carlier2019-08-051-1/+1
| | | | | | | | | | | | Disabling Transparent huge page mode refactored in one function. Reviewers: vitalybuka Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D65771 llvm-svn: 367925
* compiler-rt: Rename cc files below test/asan to cppNico Weber2019-08-051-1/+1
| | | | | | See r367803 and similar other changes. llvm-svn: 367887
* Try to fix OOB tests more on Windows after r367642Nico Weber2019-08-051-0/+7
| | | | | | | | | | | | | | | | | | See PR42868 for more details. The affected list of tests is: Failing Tests (8): AddressSanitizer-Unit :: ./Asan-x86_64-calls-Test.exe/AddressSanitizer.LargeOOBRightTest AddressSanitizer-Unit :: ./Asan-x86_64-calls-Test.exe/AddressSanitizer.OOBRightTest AddressSanitizer-Unit :: ./Asan-x86_64-calls-Test.exe/AddressSanitizer.OOB_char AddressSanitizer-Unit :: ./Asan-x86_64-calls-Test.exe/AddressSanitizer.OOB_int AddressSanitizer-Unit :: ./Asan-x86_64-inline-Test.exe/AddressSanitizer.LargeOOBRightTest AddressSanitizer-Unit :: ./Asan-x86_64-inline-Test.exe/AddressSanitizer.OOBRightTest AddressSanitizer-Unit :: ./Asan-x86_64-inline-Test.exe/AddressSanitizer.OOB_char AddressSanitizer-Unit :: ./Asan-x86_64-inline-Test.exe/AddressSanitizer.OOB_int llvm-svn: 367874
* Try to fix OOB tests on at least Windows after r367642Nico Weber2019-08-051-1/+1
| | | | | | | | | gtest's built-in regex engine doesn't support (). Looks like it's not needed, just remove it. See PR42868 for more details. llvm-svn: 367873
* Fix flaky test caused by PR42868Vitaly Buka2019-08-021-22/+21
| | | | llvm-svn: 367642
* Remove a few straggler ".cc"s in compiler-rt/libNico Weber2019-08-012-2/+2
| | | | llvm-svn: 367589
* compiler-rt: Rename .cc file in lib/asan/tests to .cppNico Weber2019-08-0115-27/+35
| | | | | | Like r367463, but for asan/tests llvm-svn: 367559
* compiler-rt: Rename .cc file in lib/asan to .cppNico Weber2019-08-0144-96/+102
| | | | | | Like r367463, but for asan. llvm-svn: 367558
* [Sanitizer][ASAN][MSAN] Fix infinite recursion on FreeBSDAlexander Richardson2019-07-311-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: MSAN was broken on FreeBSD by https://reviews.llvm.org/D55703: after this change accesses to the key variable call __tls_get_addr, which is intercepted. The interceptor then calls GetCurrentThread which calls MsanTSDGet which again calls __tls_get_addr, etc... Using the default implementation in the SANITIZER_FREEBSD case fixes MSAN for me. I then applied the same change to ASAN (introduced in https://reviews.llvm.org/D55596) but that did not work yet. In the ASAN case, we get infinite recursion again during initialization, this time because calling pthread_key_create() early on results in infinite recursion. pthread_key_create() calls sysctlbyname() which is intercepted but COMMON_INTERCEPTOR_NOTHING_IS_INITIALIZED returns true, so the interceptor calls internal_sysctlbyname() which then ends up calling the interceptor again. I fixed this issue by using dlsym() to get the libc version of sysctlbyname() instead. This fixes https://llvm.org/PR40761 Reviewers: vitalybuka, krytarowski, devnexen, dim, bsdjhb, #sanitizers, MaskRay Reviewed By: MaskRay Subscribers: MaskRay, emaste, kubamracek, jfb, #sanitizers, llvm-commits Tags: #sanitizers, #llvm Differential Revision: https://reviews.llvm.org/D65221 llvm-svn: 367442
* [asan_symbolize] More debugging outputDan Liew2019-07-311-0/+1
| | | | | | | | | When a line fails to match the stackframe regex we now report it in the log. rdar://problem/49476995 llvm-svn: 367380
* [asan_symbolize] Add `--skip-uuid-validation` option to `ModuleMapPlugIn`.Dan Liew2019-07-311-10/+26
| | | | | | | | | This option disables the validation of binary UUIDs. This is useful in environments where the `otool` binary is not available. rdar://problem/49476995 llvm-svn: 367379
* [asan_symbolize] Provide better error message when extracting the UUID of a ↵Dan Liew2019-07-311-1/+3
| | | | | | | | binary fails rdar://problem/49476995 llvm-svn: 367378
* [ASan] Fix >80 character line.Matt Morehouse2019-07-151-1/+2
| | | | llvm-svn: 366136
* [sanitizers][windows][mingw32] Mingw32 RTL fixesMatthew G McGovern2019-07-151-44/+44
| | | | | | | | | RTL interception broke mingw32, this should fix those builds by removing dependency on windows.h reviewed in https://reviews.llvm.org/D64694 llvm-svn: 366105
* Enable compiler-rt on SPARCRainer Orth2019-07-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch enables compiler-rt on SPARC targets. Most of the changes are straightforward: - Add 32 and 64-bit sparc to compiler-rt - lib/builtins/fp_lib.h needed to check if the int128_t and uint128_t types exist (which they don't on sparc) There's one issue of note: many asan tests fail to compile on Solaris/SPARC: fatal error: error in backend: Function "_ZN7testing8internal16BoolFromGTestEnvEPKcb": over-aligned dynamic alloca not supported. Therefore, while asan is still built, both asan and ubsan-with-asan testing is disabled. The goal is to check if asan keeps compiling on Solaris/SPARC. This serves asan in gcc, which doesn't have the problem above and works just fine. With this patch, sparcv9-sun-solaris2.11 test results are pretty good: Failing Tests (9): Builtins-sparc-sunos :: divtc3_test.c Builtins-sparcv9-sunos :: compiler_rt_logbl_test.c Builtins-sparcv9-sunos :: divtc3_test.c [...] UBSan-Standalone-sparc :: TestCases/TypeCheck/misaligned.cpp UBSan-Standalone-sparcv9 :: TestCases/TypeCheck/misaligned.cpp The builtin failures are due to Bugs 42493 and 42496. The tree contained a few additonal patches either currently in review or about to be submitted. Tested on sparcv9-sun-solaris2.11. Differential Revision: https://reviews.llvm.org/D40943 llvm-svn: 365880
* [ASan] Use __sanitizer_fill_shadow for FastPoisonShadow on FuchsiaPetr Hosek2019-07-111-4/+6
| | | | | | | | This is the optimized implementation for Fuchsia provided by the libc. Differential Revision: https://reviews.llvm.org/D64166 llvm-svn: 365739
* [sanitizers][windows] FIX: Rtl-Heap Interception and testsMatthew G McGovern2019-07-091-2/+2
| | | | | | | | | | | | - Adds interceptors for Rtl[Allocate|Free|Size|ReAllocate]Heap - Adds unit tests for the new interceptors and expands HeapAlloc tests to demonstrate new functionality. Reviewed as D62927 - adds fixes for ~win and x64 tests > llvm-svn: 365381 llvm-svn: 365424
* [sanitizers][windows] Rtl-Heap Interception and testsMatthew G McGovern2019-07-093-51/+335
| | | | | | | | | - Adds interceptors for Rtl[Allocate|Free|Size|ReAllocate]Heap - Adds unit tests for the new interceptors and expands HeapAlloc tests to demonstrate new functionality. Reviewed as D62927 llvm-svn: 365422
* Revert "[sanitizers][windows] Rtl-Heap Interception and tests"JF Bastien2019-07-083-335/+51
| | | | | | | | | | | | | | | | | | | | | | | | Causes build failure on clang-ppc64be-linux-lnt: compiler-rt/lib/asan/asan_malloc_win.cc:23:2: error: #error "Missing arch or unsupported platform for Windows." #error "Missing arch or unsupported platform for Windows." ^~~~~ compiler-rt/lib/asan/asan_malloc_win.cc:25:10: fatal error: heapapi.h: No such file or directory #include <heapapi.h> ^~~~~~~~~~~ compilation terminated. [39/1151] Building CXX object projects/compiler-rt/lib/asan/CMakeFiles/RTAsan.powerpc64.dir/asan_debugging.cc.o [40/1151] Building CXX object projects/compiler-rt/lib/asan/CMakeFiles/RTAsan.powerpc64.dir/asan_malloc_win.cc.o FAILED: projects/compiler-rt/lib/asan/CMakeFiles/RTAsan.powerpc64.dir/asan_malloc_win.cc.o /usr/bin/c++ -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Iprojects/compiler-rt/lib/asan -Icompiler-rt/lib/asan -Iinclude -I/home/buildbots/ppc64be-clang-lnt-test/clang-ppc64be-lnt/llvm/include -Icompiler-rt/lib/asan/.. -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wno-maybe-uninitialized -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -fdiagnostics-color -ffunction-sections -fdata-sections -Wall -std=c++11 -Wno-unused-parameter -O2 -UNDEBUG -m64 -fPIC -fno-builtin -fno-exceptions -fomit-frame-pointer -funwind-tables -fno-stack-protector -fvisibility=hidden -fno-lto -O3 -g -Wno-variadic-macros -Wno-non-virtual-dtor -fno-rtti -MD -MT projects/compiler-rt/lib/asan/CMakeFiles/RTAsan.powerpc64.dir/asan_malloc_win.cc.o -MF projects/compiler-rt/lib/asan/CMakeFiles/RTAsan.powerpc64.dir/asan_malloc_win.cc.o.d -o projects/compiler-rt/lib/asan/CMakeFiles/RTAsan.powerpc64.dir/asan_malloc_win.cc.o -c compiler-rt/lib/asan/asan_malloc_win.cc compiler-rt/lib/asan/asan_malloc_win.cc:23:2: error: #error "Missing arch or unsupported platform for Windows." #error "Missing arch or unsupported platform for Windows." ^~~~~ compiler-rt/lib/asan/asan_malloc_win.cc:25:10: fatal error: heapapi.h: No such file or directory #include <heapapi.h> ^~~~~~~~~~~ llvm-svn: 365384
* [sanitizers][windows] Rtl-Heap Interception and testsMatthew G McGovern2019-07-083-51/+335
| | | | | | | | | - Adds interceptors for Rtl[Allocate|Free|Size|ReAllocate]Heap - Adds unit tests for the new interceptors and expands HeapAlloc tests to demonstrate new functionality. Reviewed as D62927 llvm-svn: 365381
* [ASan] Use dynamic shadow on 32-bit iOS and simulatorsJulian Lettner2019-06-211-14/+2
| | | | | | | | | | | | | | | | | | | | The VM layout on iOS is not stable between releases. On 64-bit iOS and its derivatives we use a dynamic shadow offset that enables ASan to search for a valid location for the shadow heap on process launch rather than hardcode it. This commit extends that approach for 32-bit iOS plus derivatives and their simulators. rdar://50645192 rdar://51200372 rdar://51767702 Reviewed By: delcypher Differential Revision: https://reviews.llvm.org/D63586 llvm-svn: 364105
OpenPOWER on IntegriCloud