summaryrefslogtreecommitdiffstats
path: root/compiler-rt/test
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix a minor bug in testXinliang David Li2016-03-091-1/+1
| | | | llvm-svn: 263028
* [test/sanitizer-common] Linux/sanitizer_set_death_callback_test.cc -> ↵Filipe Cabecinhas2016-03-091-0/+0
| | | | | | Posix/sanitizer_set_death_callback_test.cc llvm-svn: 263018
* [test/sanitizer-common] Move getpass.cc from Linux into PosixFilipe Cabecinhas2016-03-091-0/+4
| | | | llvm-svn: 263017
* [DFSan] Fix test_inet_pton for big endian archsMohit K. Bhakkad2016-03-091-1/+1
| | | | | | | | | | Reviewers: samsonov Subscribers: ed, jaydeep, sagar, llvm-commits Differential Revision: http://reviews.llvm.org/D17751 llvm-svn: 263001
* [Fix r262788] Fix missed prototype with the old llvm* name.Filipe Cabecinhas2016-03-081-1/+1
| | | | llvm-svn: 262927
* [sanitizer-common] Use @LINE in test.Filipe Cabecinhas2016-03-071-5/+5
| | | | llvm-svn: 262828
* [powerpc] mark setuid.c and setuid2.c as unsupportedBill Seurer2016-03-072-0/+12
| | | | | | | | | setuid(0) hangs on powerpc64 big endian. When this is fixed remove the unsupported flag. https://llvm.org/bugs/show_bug.cgi?id=25799 llvm-svn: 262814
* [PGO] internal API name cleanups (for better consistency)Xinliang David Li2016-03-062-22/+22
| | | | llvm-svn: 262788
* [PGO] Add API to check compatibility of profile data in bufferXinliang David Li2016-03-043-0/+98
| | | | | | This is needed by client which uses in-process merge API. llvm-svn: 262736
* [ubsan/float-cast-overflow] Make the test also work with C++11 narrowingFilipe Cabecinhas2016-03-041-4/+4
| | | | llvm-svn: 262733
* [powerpc] pacify lint for java_race_pc.ccBill Seurer2016-03-041-2/+0
| | | | | | Fix blank lines. llvm-svn: 262689
* [asan] Fix odr_c_test failure with gold linkerAlexey Samsonov2016-03-041-0/+3
| | | | | | | | | | | Summary: Adds another global to asan's odr_c_test to help force the target global to not lie at the start of bss with the gold linker where it is always aligned. Patch by Derek Bruening! llvm-svn: 262678
* [powerpc] activate java_race_pc.cc on powerpc64leBill Seurer2016-03-041-0/+1
| | | | | | | | | The test case compiler-rt/test/tsan/java_race_pc.cc fails on powerpc64 big endian but not little endian. Add missing blank line. llvm-svn: 262675
* [powerpc] activate java_race_pc.cc on powerpc64leBill Seurer2016-03-031-2/+3
| | | | | | | The test case compiler-rt/test/tsan/java_race_pc.cc fails on powerpc64 big endian but not little endian. llvm-svn: 262669
* [PGO] Add API for profile merge from bufferXinliang David Li2016-03-033-0/+210
| | | | | | Differential Revision: http://reviews.llvm.org/D17831 llvm-svn: 262644
* [test/ubsan/coverage-levels] Fix file references in UBSAN_OPTIONSFilipe Cabecinhas2016-03-031-5/+5
| | | | llvm-svn: 262632
* [LSan] Enable use_registers test for MIPSMohit K. Bhakkad2016-03-031-0/+5
| | | | | | | | | | Reviewers: samsonov Subscribers: jaydeep, sagar, llvm-commits Differential Revision: http://reviews.llvm.org/D17797 llvm-svn: 262581
* Fix minor bug in testXinliang David Li2016-03-021-1/+1
| | | | llvm-svn: 262514
* [TSAN] Fix test java_race_pcSagar Thakur2016-03-022-2/+12
| | | | | | | | | Incremented the pc for each architecture in accordance with StackTrace:GetPreviousInstructionPC Reviewers: samsonov, dvyukov Subscribers: llvm-commits, mohit.bhakkad, jaydeep Differential: http://reviews.llvm.org/D17802 llvm-svn: 262483
* Revert "[RT] Make tsan tests more portable"Renato Golin2016-03-0251-63/+63
| | | | | | This reverts commit r262476, as it broken the AArch64 VMA42 buildbot. llvm-svn: 262479
* [RT] Make tsan tests more portableRenato Golin2016-03-0251-63/+63
| | | | | | | | by avoiding potential races when scanning stdout and stderr output. Patch by Maxim Kuvyrkov. llvm-svn: 262476
* [test/vptr-non-unique-typeinfo] Address Samsonov's post-commit reviewFilipe Cabecinhas2016-03-024-14/+15
| | | | | | | | | | Reviewers: samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D17783 llvm-svn: 262469
* [Compiler-rt][MSan] fix param_tls_limit test for platforms where big ↵Mohit K. Bhakkad2016-03-011-4/+15
| | | | | | | | | | | | arguments are sliced in smaller ones Reviewers: eugenis Subscribers: dsanders, jaydeep, sagar, llvm-commits Differential Revision: http://reviews.llvm.org/D17129 llvm-svn: 262302
* [asan] Retry failed adb commands in android tests.Evgeniy Stepanov2016-03-011-10/+15
| | | | | | | Add limited retries for push/pull adb commands in android tests. May help with the adb flakiness. llvm-svn: 262283
* [asan] Fix new[]/delete mismatch in tests.Evgeniy Stepanov2016-03-011-1/+1
| | | | | | | This code is actually never executed because all RUN lines trigger an earlier heap-use-after-free, but there is still a compiler warning. llvm-svn: 262276
* Avoid use of -fsanitize=vptr in MSVC env, it is not yet supportedReid Kleckner2016-02-291-0/+2
| | | | llvm-svn: 262251
* [asan] Fix UB in test/asan/TestCases/Linux/recvfrom.cc testcase.Maxim Ostapenko2016-02-291-1/+1
| | | | llvm-svn: 262210
* Update the link of issueMohit K. Bhakkad2016-02-291-1/+1
| | | | llvm-svn: 262209
* [asan] Re-enable test/asan/TestCases/Linux/recvfrom.cc testcase.Maxim Ostapenko2016-02-291-49/+39
| | | | | | | | | | | This testcase failed on sanitizer-x86_64-linux buildbot in large parallel build due to race on port 1234 between AddressSanitizer-i386-linux and AddressSanitizer-x86_64-linux instances of recvfrom.cc. This patch tries to resolve the issue by relying on kernel to choose available port instead of hardcoding its number in testcase. Differential Revision: http://reviews.llvm.org/D17639 llvm-svn: 262204
* Test cleanupsXinliang David Li2016-02-283-6/+6
| | | | llvm-svn: 262162
* [PGO] add a test for available_externally functionsXinliang David Li2016-02-285-0/+78
| | | | llvm-svn: 262161
* [UBSan] Fix isDerivedFromAtOffset on iOS ARM64Filipe Cabecinhas2016-02-274-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: iOS on ARM64 doesn't unique RTTI. Ref: clang's iOS64CXXABI::shouldRTTIBeUnique() Due to this, pointer-equality will not necessarily work in this architecture, across dylib boundaries. dynamic_cast<>() will (as expected) still work, since Apple ships with one prepared for this, but we can't rely on the type names being pointer-equal. I've limited the expensive strcmp check to the specific architecture which needs it. Example which triggers this bug: lib.h: struct X { virtual ~X() {} }; X *libCall(); lib.mm: X *libCall() { return new X; } prog.mm: int main() { X *px = libCall(); delete px; } Expected output: Nothing Actual output: <unknown>: runtime error: member call on address 0x00017001ef50 which does not point to an object of type 'X' 0x00017001ef50: note: object is of type 'X' 00 00 00 00 60 00 0f 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ^~~~~~~~~~~~~~~~~~~~~~~ vptr for ‘X’ Reviewers: kubabrecka, samsonov, eugenis, rsmith Subscribers: aemerson, llvm-commits, rengolin Differential Revision: http://reviews.llvm.org/D11502 llvm-svn: 262147
* Use relative lines in CHECKs in race_on_mutex.cAlexander Kornienko2016-02-261-15/+14
| | | | llvm-svn: 262000
* [TSAN] XFAIL race_on_mutex.cc for MIPSSagar Thakur2016-02-261-0/+4
| | | | | | | | This test expects pthread_mutex_init in the frame #0 of thread T1 but we get memset at frame #0 because memset that is called from pthread_init_mutex is being intercepted by TSan llvm-svn: 261986
* [MSan] Endianness should not matter while printing a byteMohit K. Bhakkad2016-02-261-1/+1
| | | | | | | | | | | Reviewers: eugenis Subscribers: jaydeep, sagar, llvm-commits Differential Revision: http://reviews.llvm.org/D17264 Differential Revision: http://reviews.llvm.org/D17563 llvm-svn: 261982
* [powerpc] reactivate ignore_lib4.cc on powerpc64leBill Seurer2016-02-251-2/+3
| | | | | | | The test case compiler-rt/test/tsan/ignore_lib4.cc fails on powerpc64 big endian but not little endian. llvm-svn: 261900
* [sanitizer] Fix third parameter in COMMON_INTERCEPTOR_WRITE_RANGE in recv ↵Maxim Ostapenko2016-02-251-1/+1
| | | | | | | | | | | and recvfrom interceptors. Pass res instead of len as third parameter to COMMON_INTERCEPTOR_WRITE_RANGE, because otherwise we can write to unrelated memory (in MSan) or get wrong report (in ASan). Differential Revision: http://reviews.llvm.org/D17608 llvm-svn: 261898
* [asan] Disable recvfrom test failing on the bots.Maxim Ostapenko2016-02-251-0/+2
| | | | llvm-svn: 261870
* [asan] Disable recvfrom testcase on Android due to buildbot failure.Maxim Ostapenko2016-02-251-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Trying to fix following error on Android: FAIL: AddressSanitizer-arm-android :: TestCases/Linux/recvfrom.cc (47 of 350) ... Command Output (stderr): -- /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:22:22: error: variable has incomplete type 'struct sockaddr_in' struct sockaddr_in serveraddr; // server's addr ^ /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:22:10: note: forward declaration of 'sockaddr_in' struct sockaddr_in serveraddr; // server's addr ^ /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:29:38: error: use of undeclared identifier 'INADDR_ANY' serveraddr.sin_addr.s_addr = htonl(INADDR_ANY); ^ /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:30:25: error: use of undeclared identifier 'htons' serveraddr.sin_port = htons(kPortNum); ^ /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:45:22: error: variable has incomplete type 'struct sockaddr_in' struct sockaddr_in serveraddr; // server's addr ^ /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:45:10: note: forward declaration of 'sockaddr_in' struct sockaddr_in serveraddr; // server's addr ^ /mnt/b/sanitizer-buildbot1/sanitizer-x86_64-linux/build/llvm/projects/compiler-rt/test/asan/TestCases/Linux/recvfrom.cc:69:25: error: use of undeclared identifier 'htons' serveraddr.sin_port = htons(kPortNum); llvm-svn: 261855
* [sanitizer] Move recvmsg and recv interceptors to sanitizer_common.Maxim Ostapenko2016-02-251-0/+79
| | | | | | | | | This patch moves recv and recvfrom interceptors from MSan and TSan to sanitizer_common to enable them in ASan. Differential Revision: http://reviews.llvm.org/D17479 llvm-svn: 261841
* [MSAN] Fix memcmp_test on MIPSSagar Thakur2016-02-241-1/+4
| | | | | | | | | Summary: As per the test the 4th element of both arrays are not initialized and hence will contain garbage values. Memcmp returns the difference between the garbage values of the 4th element which will be different on every run of the test. And since the return value of memcmp is returned from main, we are getting random exit code every time. Reviewers: kcc, eugenis Subscribers: mohit.bhakkad, jaydeep, llvm-commits Differential: http://reviews.llvm.org/D17534 llvm-svn: 261739
* tsan: disable ignore_lib4.cc test on powerpc64 and aarch64Dmitry Vyukov2016-02-241-0/+5
| | | | | | | | | | Fails on bots: http://lab.llvm.org:8011/builders/clang-ppc64be-linux/builds/1555/steps/ninja%20check%201/logs/FAIL%3A%20ThreadSanitizer-powerpc64%3A%3A%20ignore_lib4.cc http://lab.llvm.org:8011/builders/sanitizer-ppc64be-linux/builds/725/steps/ninja%20check-tsan/logs/stdio http://lab.llvm.org:8011/builders/clang-cmake-aarch64-full/builds/1468/steps/ninja%20check%202/logs/FAIL%3A%20ThreadSanitizer-aarch64%3A%3A%20ignore_lib4.cc http://lab.llvm.org:8011/builders/clang-native-aarch64-full/builds/2787/steps/ninja%20check%202/logs/FAIL%3A%20ThreadSanitizer-aarch64%3A%3A%20ignore_lib4.cc llvm-svn: 261728
* [MSan] fix process_vm_readv test: Exit silently if syscall is not implemetedMohit K. Bhakkad2016-02-241-7/+15
| | | | | | | | | | Reviewers: eugenis Subscribers: jaydeep, sagar, llvm-commits Differential Revision: http://reviews.llvm.org/D17560 llvm-svn: 261723
* [MSan] Mark dlerror.cc expected failure for MIPSMohit K. Bhakkad2016-02-241-1/+2
| | | | | | | | | | Reviewers: samsonov Subscribers: jaydeep, sagar, llvm-commits, aemerson Differential Revision: http://reviews.llvm.org/D17503 llvm-svn: 261721
* [tests] Don't compile CFI C tests in C++ mode.Alexey Samsonov2016-02-243-7/+13
| | | | llvm-svn: 261708
* tsan: clean up code after r261658Dmitry Vyukov2016-02-232-2/+2
| | | | llvm-svn: 261660
* tsan: fix signal handling in ignored librariesDmitry Vyukov2016-02-233-0/+119
| | | | | | | | | | | | | | The first issue is that we longjmp from ScopedInterceptor scope when called from an ignored lib. This leaves thr->in_ignored_lib set. This, in turn, disables handling of sigaction. This, in turn, corrupts tsan state since signals delivered asynchronously. Another issue is that we can ignore synchronization in asignal handler, if the signal is delivered into an IgnoreSync region. Since signals are generally asynchronous, they should ignore memory access/synchronization/interceptor ignores. This could lead to false positives in signal handlers. llvm-svn: 261658
* [tests] Run test that uses gnu asm syntax on Posix only.Alexey Samsonov2016-02-231-0/+0
| | | | llvm-svn: 261609
* [tests] Remove "supported-target" in favor of "target-arch" lit features.Alexey Samsonov2016-02-2322-27/+26
| | | | | | | | | | Test cases definitely should not care about the complete set of architectures supported by compiler-rt - they should only care about current architecture that the test suite was configured for. Introduce new lit feature to reflect this, and convert tests to use it. llvm-svn: 261603
* [tests] Always specify correct config.target_arch when configuring test suite.Alexey Samsonov2016-02-2311-17/+25
| | | | llvm-svn: 261601
OpenPOWER on IntegriCloud