summaryrefslogtreecommitdiffstats
path: root/compiler-rt/test/sanitizer_common/TestCases/Linux
Commit message (Collapse)AuthorAgeFilesLines
...
* [sanitizer] Relax stack check in assert.cc even moreVitaly Buka2017-11-131-1/+0
| | | | | | assert implementations can be very different llvm-svn: 318089
* [tsan] Fix signal chainingVitaly Buka2017-11-131-4/+0
| | | | | | | | | | | | Summary: Return saved values only if installed sigaction is our wrapper. Reviewers: eugenis, dvyukov Subscribers: llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D39935 llvm-svn: 318082
* [tsan] Deadly signal handler for tsanVitaly Buka2017-11-132-6/+0
| | | | | | | | | | | | Summary: https://github.com/google/sanitizers/issues/637 Reviewers: eugenis Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D39929 llvm-svn: 318078
* [sanitizer] Relax stack checkVitaly Buka2017-11-131-1/+1
| | | | | | -NEXT sometimes does not work as LLVMSymbolizer warning can appear there. llvm-svn: 318077
* [sanitizer] Simplify stack check in accert.ccVitaly Buka2017-11-121-2/+2
| | | | | | Somehow on arm bots stack does not include main. llvm-svn: 318002
* [sanitizer] Try to see test output on armv7Vitaly Buka2017-11-121-0/+1
| | | | llvm-svn: 318001
* [msan] Fix signal chainingVitaly Buka2017-11-111-3/+3
| | | | | | Return internally stored handlers only if handlers is set to wrapper llvm-svn: 317970
* [sanitizer] Include stack trace check into signal testsVitaly Buka2017-11-112-2/+8
| | | | llvm-svn: 317963
* [ubsan] Fix ubsan tests broken by linking as C instead of C++Vitaly Buka2017-11-111-3/+2
| | | | llvm-svn: 317958
* [msan] Deadly signal handler for msanVitaly Buka2017-11-102-2/+0
| | | | | | | | | | | | Summary: Part of https://github.com/google/sanitizers/issues/637 Reviewers: eugenis, alekseyshl Subscribers: llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D39826 llvm-svn: 317864
* Revert "[asan] Deflake one test by running it 3 times."Evgeniy Stepanov2017-10-171-18/+3
| | | | | | Disable this test on Android/x86 only. llvm-svn: 316023
* [asan] Deflake one test by running it 3 times.Evgeniy Stepanov2017-10-131-3/+18
| | | | | | The test seems to trigger an android platform bug under load. llvm-svn: 315777
* [sanitizer] Workaround a Linux kernel bug in hard_rss_limit_mb_test.Evgeniy Stepanov2017-10-121-7/+6
| | | | llvm-svn: 315632
* [asan] Disable a flaky test on android.Evgeniy Stepanov2017-10-121-0/+3
| | | | llvm-svn: 315602
* [asan] Tweak test output to diagnose buildbot failures.Evgeniy Stepanov2017-10-111-2/+6
| | | | llvm-svn: 315479
* [sanitizer] Re-disable several tests on Android.Evgeniy Stepanov2017-10-111-1/+1
| | | | | | The tests have been enabled by accident in r315389. llvm-svn: 315396
* [mips][compiler-rt] Disable sem_init_glibc.cc for MIPS64.Simon Dardis2017-09-251-1/+1
| | | | | | | | | | | This test can't pass on MIPS64 due to the lack of versioned interceptors for asan and company. The interceptors bind to the earlier version of sem_init rather than the latest version. For MIPS64el this causes an accidental pass while MIPS64 big endian fails due reading back a different 32bit word to what sem_init wrote when the test is corrected to use 64bit atomics. llvm-svn: 314100
* [ubsan] Fix assert.cc test by compiling it as C++Vitaly Buka2017-09-231-2/+1
| | | | llvm-svn: 314057
* [ubsan] Support signal specific options in ubsanVitaly Buka2017-09-231-1/+0
| | | | | | | | | | | | | | | | Summary: Part of https://github.com/google/sanitizers/issues/637 Standalone ubsan needs signal and sigaction handlers and interceptors. Plugin mode should rely on parent tool. Reviewers: eugenis, alekseyshl Subscribers: kubamracek, llvm-commits, mgorny Differential Revision: https://reviews.llvm.org/D37895 llvm-svn: 314052
* [lsan] Deadly signal handler for lsanVitaly Buka2017-09-223-5/+3
| | | | | | | | | | | | Summary: Part of https://github.com/google/sanitizers/issues/637 Reviewers: eugenis, alekseyshl Subscribers: llvm-commits, dberris, kubamracek, krytarowski Differential Revision: https://reviews.llvm.org/D37608 llvm-svn: 314041
* [mips][compiler-rt] UnXFAIL test.Simon Dardis2017-09-191-2/+0
| | | | | | lsan and asan were reporting leaks caused by a glibc configuration issue. llvm-svn: 313645
* [sanitizer] Fix check for i386 Android in lit testsVitaly Buka2017-09-161-1/+1
| | | | llvm-svn: 313452
* [sanitizer] Disable sanitizer test which already fails on Android i386Vitaly Buka2017-09-161-0/+3
| | | | llvm-svn: 313447
* [sanitizer] Support check-asan on AndroidVitaly Buka2017-09-164-0/+10
| | | | | | This patch enabled asan tests from sanitizer_common. llvm-svn: 313444
* [sanitizer] Simplify checks in allow_user_segv.ccVitaly Buka2017-09-151-6/+6
| | | | llvm-svn: 313342
* [lsan] Disable clang-format on few RUN: statementsVitaly Buka2017-09-152-0/+8
| | | | llvm-svn: 313321
* Revert "[mips] Fix sem_init_glibc test for MIPS."Simon Dardis2017-09-141-5/+3
| | | | | | | | | | | The commit did not fix the failing test and instead exposed an inconsistency between lsan and (t|m|a)san. I'm reverting the patch as it causes more failures and the original patch had a '||' instead of '&&', which meant that an N32 build of test would have be incorrect w.r.t. __HAVE_64B_ATOMICS for glibc. This reverts commit r313248. llvm-svn: 313291
* [mips] Fix sem_init_glibc test for MIPS.Simon Dardis2017-09-141-3/+5
| | | | | | | | | | | | | | | glibc changed the implementation of semaphores for glibc 2.21 requiring some target specific changes for this compiler-rt test. Modify the test to cope with MIPS64 and do some future/correctness work by tying the define for MIPS64 to exactly the define of __HAVE_64B_ATOMICS in glibc. Contributions from Nitesh Jain. Reviewers: eugenis Differential Revision: https://reviews.llvm.org/D37829 llvm-svn: 313248
* [sanitizer] Mark allow_user_segv as XFAIL instead of UNSUPPORTEDVitaly Buka2017-09-141-4/+4
| | | | llvm-svn: 313241
* [ubsan] Enable UBsan in sanitizer_common testsVitaly Buka2017-09-0911-5/+12
| | | | | | | | | | | | | | Summary: Failing tests just marked as UNSUPPORTED or XFAIL. Some of them can be easily supported, but I'll do this in separate patches. Reviewers: eugenis, alekseyshl Subscribers: srhines, kubamracek, llvm-commits, mgorny Differential Revision: https://reviews.llvm.org/D37630 llvm-svn: 312860
* [compiler-rt] Move allow_user_segv.cc into sanitizer_commonVitaly Buka2017-09-091-0/+92
| | | | | | | | | | | | Summary: Part of https://github.com/google/sanitizers/issues/637 Reviewers: eugenis Subscribers: kubamracek, dberris, llvm-commits Differential Revision: https://reviews.llvm.org/D37537 llvm-svn: 312859
* Revert "[compiler-rt] Include thread ID into sanitizers logs"Vitaly Buka2017-07-251-23/+0
| | | | | | | | This improvement introduce additional dependencies on sandboxed environments. This reverts commit r308637. llvm-svn: 308984
* [compiler-rt] Include thread ID into sanitizers logsVitaly Buka2017-07-201-0/+23
| | | | | | | | | | Reviewers: kcc, alekseyshl Subscribers: kubamracek, llvm-commits, dberris Differential Revision: https://reviews.llvm.org/D35654 llvm-svn: 308637
* Revert r304285, r304297.Evgeniy Stepanov2017-06-051-118/+0
| | | | | | | | | | | r304285 - [sanitizer] Avoid possible deadlock in child process after fork r304297 - [sanitizer] Trying to fix MAC buildbots after r304285 These changes create deadlock when Tcl calls pthread_create from a pthread_atfork child handler. More info in the original review at https://reviews.llvm.org/D33325 llvm-svn: 304735
* [sanitizer] Avoid possible deadlock in child process after forkMaxim Ostapenko2017-05-311-0/+118
| | | | | | | | | | | | | | This patch addresses https://github.com/google/sanitizers/issues/774. When we fork a multi-threaded process it's possible to deadlock if some thread acquired StackDepot or allocator internal lock just before fork. In this case the lock will never be released in child process causing deadlock on following memory alloc/dealloc routine. While calling alloc/dealloc routines after multi-threaded fork is not allowed, most of modern allocators (Glibc, tcmalloc, jemalloc) are actually fork safe. Let's do the same for sanitizers except TSan that has complex locking rules. Differential Revision: https://reviews.llvm.org/D33325 llvm-svn: 304285
* [compiler-rt] Replace allow_user_segv_handler=0 with kHandleSignalExclusiveVitaly Buka2017-05-251-1/+1
| | | | | | | | | | | | | | Summary: allow_user_segv_handler had confusing name did not allow to control behavior for signals separately. Reviewers: eugenis, alekseyshl, kcc Subscribers: llvm-commits, dberris, kubamracek Differential Revision: https://reviews.llvm.org/D33371 llvm-svn: 303941
* [PowerPC] Fix test case sem_init_glibc.cc for powerpc64beBill Seurer2017-05-251-1/+5
| | | | | | | This test case fails on powerpc64be with older glibcs because of the glibc version test. llvm-svn: 303863
* [mips] XFAIL getpwnam_r_invalid_user.cc testSimon Dardis2017-05-101-0/+2
| | | | | | XFAIL this test while we investigate the root cause. llvm-svn: 302635
* [asan] print the 'unexpected format specifier in printf interceptor' warning ↵Kostya Serebryany2017-05-031-0/+12
| | | | | | just once (came up in https://github.com/google/oss-fuzz/pull/562). Not touching a similar scanf warning -- for some reason it does not fire for me. llvm-svn: 302064
* [sanitizer] Intercept mcheck and mprobe on LinuxMaxim Ostapenko2017-05-031-0/+42
| | | | | | | | | This patch addresses https://github.com/google/sanitizers/issues/804. Users can use mcheck and mprobe functions to verify heap state so we should intercept them to avoid breakage of valid code. Differential Revision: https://reviews.llvm.org/D32589 llvm-svn: 302001
* [msan] fix iconv interceptor. before the fix the interceptor failed to mark ↵Kostya Serebryany2017-04-121-0/+28
| | | | | | memory as initialized if iconv returned -1. Found in a hard way while fuzzing libxml2 :( llvm-svn: 300010
* Bypass potential libc's sysconf interceptorsAlex Shlyapnikov2017-03-231-0/+25
| | | | | | | | | | | | | | | | | | Summary: sysconf(_SC_PAGESIZE) is called very early during sanitizer init and any instrumented code (sysconf() wrapper/interceptor will likely be instrumented) calling back to sanitizer before init is done will most surely crash. 2nd attempt, now with glibc version checks (D31092 was reverted). Reviewers: eugenis Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D31221 llvm-svn: 298613
* Revert "Bypass potential libc's sysconf wrappers for sysconf(_SC_PAGESIZE) call"Vitaly Buka2017-03-211-21/+0
| | | | | | | | Bot can't find <sys/auxv.h> This reverts commit r298305. llvm-svn: 298343
* Bypass potential libc's sysconf wrappers for sysconf(_SC_PAGESIZE) callAlex Shlyapnikov2017-03-201-0/+21
| | | | | | | | | | | | | | | Summary: sysconf(_SC_PAGESIZE) is called very early, during sanitizer init and any instrumented code (a wrapper/interceptor will likely be instrumented) calling back to sanitizer before init is done will most surely crash. Reviewers: eugenis Subscribers: llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D31092 llvm-svn: 298305
* [sanitizer] Bail out with warning if user dlopens shared library with ↵Maxim Ostapenko2017-03-091-0/+12
| | | | | | | | | | | | RTLD_DEEPBIND flag People keep hitting on spurious failures in malloc/free routines when using sanitizers with shared libraries dlopened with RTLD_DEEPBIND (see https://github.com/google/sanitizers/issues/611 for details). Let's check for this flag and bail out with warning message instead of failing in random places. Differential Revision: https://reviews.llvm.org/D30504 llvm-svn: 297370
* [lsan] Disable sem_init_glibc.cc testcase for LSan x86.Maxim Ostapenko2017-02-031-1/+1
| | | | | | | | | | This test relies on sanitizer common interceptor to pick the oldest version of sem_init function from Glibc. But LSan actually doesn't intercept sem_init, thus the new implementation is called that causes test failure. Disable it for LSan x86, the proper fix would require to check Glibc version at runtime and adjust GET_SEM_VALUE(V) accordingly. llvm-svn: 294001
* [asan] Support handle_sigfpe on DarwinJustin Bogner2017-02-011-30/+0
| | | | llvm-svn: 293746
* [sanitizer] Support SANITIZER_INTERCEPTOR_HOOKS on DarwinJustin Bogner2017-02-011-82/+0
| | | | | | | This basically already worked other than weak symbols needing definitions on darwin. llvm-svn: 293741
* [asan] Disable yet another unstable test under AArch64Renato Golin2016-12-071-0/+1
| | | | llvm-svn: 288953
* [sanitizers] Update sanitizers test to better match glibc internalsDiana Picus2016-10-051-2/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reapply 282061. One of the tests relying on sem_t's layout gets the wrong value for versions of glibc newer than 2.21 on platforms that don't have 64-bit atomics (e.g. ARM). This commit fixes the test to work with: * versions of glibc >= 2.21 on platforms with 64-bit atomics: unchanged * versions of glibc >= 2.21 on platforms without 64-bit atomics: the semaphore value is shifted by SEM_VALUE_SHIFT (which is set to 1 in glibc's internal headers) * versions of glibc < 2.21: unchanged The logic is complicated a bit by the fact that the sanitizers always pick the oldest version of the symbol available in glibc, which creates discrepancies between old platforms which contain several versions od the sem_init symbol, and newer platforms which contain only one. See the glibc 2.23 sources: * sysdeps/nptl/internaltypes.h (struct new_sem for glibc >= 2.21 and struct old_sem for glibc < 2.21) * nptl/sem_getvalue.c This was uncovered on one of the new buildbots that we are trying to move to production. Differential Revision: https://reviews.llvm.org/D24766 llvm-svn: 283299
OpenPOWER on IntegriCloud