summaryrefslogtreecommitdiffstats
path: root/compiler-rt
Commit message (Collapse)AuthorAgeFilesLines
* [CMake] Actually adding the TODO comment I mentioned in r252927.Chris Bieneman2015-11-121-0/+3
| | | | | | Turns out you need to save before committing. llvm-svn: 252928
* [CMake] [builtins] Adding missing architecture-specific builtins.Chris Bieneman2015-11-121-0/+8
| | | | | | Also added a TODO comment to make the build system throw an error if the CMakeLists gets out of sync again. llvm-svn: 252927
* tsan: fix windows Go buildDmitry Vyukov2015-11-122-1/+3
| | | | | | | | | | | Go build does not link in whatever library provides these symbols: # runtime/race race_windows_amd64.syso:gotsan.cc:(.text+0x578f): undefined reference to `__sanitizer::DumpProcessMap()' race_windows_amd64.syso:gotsan.cc:(.text+0xee33): undefined reference to `EnumProcessModules' race_windows_amd64.syso:gotsan.cc:(.text+0xeeb9): undefined reference to `GetModuleInformation' llvm-svn: 252922
* tsan: fix windows Go buildDmitry Vyukov2015-11-121-0/+2
| | | | | | CompareModulesBase is an unused function. llvm-svn: 252907
* [tsan] Add global symbolication support into DlAddrSymbolizerKuba Brecka2015-11-122-2/+37
| | | | | | | | `DlAddrSymbolizer` is used on OS X when we're running inside a sandbox that prevents us from spawning an external symbolizer. This patch adds support for symbolication of globals (implements `SymbolizeData`) for `DlAddrSymbolizer`. Differential Revision: http://reviews.llvm.org/D14613 llvm-svn: 252899
* [tsan] Allow symbolizers that don't obtain global symbol sizesKuba Brecka2015-11-124-6/+11
| | | | | | | | The default symbolizer, `llvm-symbolizer` provides sizes for global symbols. On OS X, we want to also allow using `atos` (because it's available everywhere and users don't need to copy/install it) and `dladdr` (it's the only available option when running in a sandbox). However, these symbolizers do not supply the symbol sizes, only names and starting addresses. This patch changes the reporting functions to hide the size of the symbol when this value is unavailable, and modifies tests to make this part of the report "optional". Differential Revision: http://reviews.llvm.org/D14608 llvm-svn: 252896
* tsan: disable abort_on_error for GoDmitry Vyukov2015-11-121-1/+5
| | | | | | | It does not work as expected. Go runtime handles SIGABRT and crashes with a loud message. llvm-svn: 252892
* [tsan] Add a Darwin-specific lit test directoryKuba Brecka2015-11-123-1/+23
| | | | | | Differential Revision: http://reviews.llvm.org/D14610 llvm-svn: 252887
* tsan: fix Go build on linuxDmitry Vyukov2015-11-122-2/+2
| | | | | | librt is not linked in in Go build. llvm-svn: 252877
* [asan] Remove system_malloc_zoneKuba Brecka2015-11-121-14/+3
| | | | | | | | This seems to be dead code – `system_malloc_zone` is initialized as null and we never assign to it. This code is apparently currently never executed (in ASan), but is causes trouble for the TSan OS X port. Let's replace the checks with `COMMON_MALLOC_ENTER` (`ENSURE_ASAN_INITED()`). Differential Revision: http://reviews.llvm.org/D14334 llvm-svn: 252876
* tsan: fix unused function warning in Go buildDmitry Vyukov2015-11-121-1/+1
| | | | llvm-svn: 252875
* tsan: fix mac Go buildDmitry Vyukov2015-11-121-2/+2
| | | | | | cur_thread does not exist in Go. llvm-svn: 252874
* [tsan] Filter OS X architectures for unit testingKuba Brecka2015-11-121-1/+5
| | | | | | | | The TSan unit test build currently fails if we're also building the iOS parts of compiler-rt, because `TSAN_SUPPORTED_ARCH` contains ARM64. For unit tests, we need to filter this only to host architecture(s). Differential Revision: http://reviews.llvm.org/D14604 llvm-svn: 252873
* tsan: fix flakiness of sleep_sync2 testDmitry Vyukov2015-11-121-1/+4
| | | | llvm-svn: 252869
* [sanitizer coverage] reset global counters in __sanitizer_reset_coverageKostya Serebryany2015-11-112-0/+7
| | | | llvm-svn: 252815
* [CMake] [Darwin] [Builtins] Force setting the flags we care about at the end ↵Chris Bieneman2015-11-111-9/+11
| | | | | | | | of the compiler command line Setting CMAKE_*_FLAGS isn't sufficient here because CMAKE_*_FLAGS_${CMAKE_BUILD_TYPE} can override the flags, and there is no way to safely clear that because it is a cached variable (<sarcasm> YAY! </sarcasm>). llvm-svn: 252807
* [asan] Remove a flaky test.Evgeniy Stepanov2015-11-111-109/+0
| | | | llvm-svn: 252805
* [Windows] Add exports for dll_host test broken by r252071 and r251071Reid Kleckner2015-11-111-0/+2
| | | | llvm-svn: 252784
* tsan: fix unused variable in Go buildDmitry Vyukov2015-11-111-6/+6
| | | | llvm-svn: 252746
* Revert r252683 - "Sancov in C++."Diego Novillo2015-11-112-288/+0
| | | | | | | | This reverts commits r252683 and r252689. This tool should not live here. See http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20151109/311862.html for discussion. llvm-svn: 252744
* [ASan] Improve portability of new tests.Yury Gribov2015-11-112-2/+7
| | | | llvm-svn: 252742
* [tsan] Rename tsan_test_util_linux.cc to tsan_test_util_posix.ccKuba Brecka2015-11-112-2/+2
| | | | | | Differential Revision: http://reviews.llvm.org/D14575 llvm-svn: 252741
* Implement some TLS support for PowerPC64.Jay Foad2015-11-113-8/+34
| | | | | | | | | | | | Summary: This is enough to get the asan static_tls.cc test case working. Reviewers: eugenis, samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D14574 llvm-svn: 252738
* Fixing #include order in tsan_new_delete.cc. Follow-up commit for r252284.Kuba Brecka2015-11-111-1/+1
| | | | llvm-svn: 252735
* [tsan] Add TSan unit test support for OS XKuba Brecka2015-11-119-40/+103
| | | | | | | | This patch enables building and running TSan unit tests on OS X. Differential Revision: http://reviews.llvm.org/D14546 llvm-svn: 252731
* Fix #if tests for PTRACE_GETREGS and others.Jay Foad2015-11-111-3/+6
| | | | | | | | | | | | | | | | | | Summary: On PowerPC64 Linux PTRACE_GETREGS is a #define and PT_GETREGS is not. On other systems it's the other way round. Extend the #ifs to check for both PTRACE_* and PT_*. This fixes test/sanitizer_common/TestCases/Linux/ptrace.cc when msan is enabled for PowerPC64. Reviewers: zatrazz, kcc, eugenis, samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D14564 llvm-svn: 252730
* [ASan] Add stress test for asynch signals in nonhalting mode.Yury Gribov2015-11-111-0/+106
| | | | | | Differential Revision: http://reviews.llvm.org/D14241 llvm-svn: 252729
* [Asan] Added missing hunk to previous commit.Yury Gribov2015-11-111-7/+2
| | | | llvm-svn: 252724
* [ASan] Enable optional ASan recovery.Yury Gribov2015-11-1110-88/+320
| | | | | | Differential Revision: http://reviews.llvm.org/D12318 llvm-svn: 252723
* sanitizer: speedup coverage by 33%Dmitry Vyukov2015-11-111-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Atomic RMW is not necessary in InitializeGuardArray. It is supposed to run when no user code runs. And if user code runs concurrently, then the atomic RMW won't help anyway. So replace it with non-atomic RMW. InitializeGuardArray takes more than 50% of time during re2 fuzzing: real 0m47.215s 51.56% a.out a.out [.] __sanitizer_reset_coverage 6.68% a.out a.out [.] __sanitizer_cov 3.41% a.out a.out [.] __sanitizer::internal_bzero_aligned16(void*, unsigned long) 1.79% a.out a.out [.] __asan::Allocator::Allocate(unsigned long, unsigned long, With this change: real 0m31.661s 26.21% a.out a.out [.] sanitizer_reset_coverage 10.12% a.out a.out [.] sanitizer_cov 5.38% a.out a.out [.] __sanitizer::internal_bzero_aligned16(void*, unsigned long) 2.53% a.out a.out [.] __asan::Allocator::Allocate(unsigned long, unsigned long, That's 33% speedup. Reviewed in http://reviews.llvm.org/D14537 llvm-svn: 252715
* Implement `internal_start/join_thread` on Mac OS XIsmail Pazarbasi2015-11-111-2/+12
| | | | | | | | | | | | | | Summary: Depends on D9637 Test Plan: Reviewers: kcc, glider, samsonov Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D9638 llvm-svn: 252696
* [tsan] Pass correct interposed function prefix to report functionIsmail Pazarbasi2015-11-111-1/+7
| | | | | | | | | | | | | | Summary: On Darwin, interposed functions are prefixed with "wrap_". On Linux, they are prefixed with "__interceptor_". Reviewers: dvyukov, samsonov, glider, kcc, kubabrecka Subscribers: zaks.anna, llvm-commits Differential Revision: http://reviews.llvm.org/D14512 llvm-svn: 252695
* Disabling sancov.cc on windows.Mike Aizatsky2015-11-111-2/+4
| | | | | | | | | It can't be built due to cxxabi missing. Will fix later. Differential Revision: http://reviews.llvm.org/D14559 llvm-svn: 252689
* Sancov in C++.Mike Aizatsky2015-11-112-0/+286
| | | | | | | | | | Summary: First batch of sancov.py rewrite in C++. Supports "-print" and "-covered_functions" commands. Differential Revision: http://reviews.llvm.org/D14356 llvm-svn: 252683
* [CMake] [macho_embedded] Only set sys root if the variable is set, this ↵Chris Bieneman2015-11-101-1/+5
| | | | | | | | prevents passing empty -isysroot arguments This is a minor cleanup to the macho_embedded builtins. llvm-svn: 252619
* [CMake] Cleaning up flags for Darwin builtinsChris Bieneman2015-11-101-23/+4
| | | | | | | * Setting CMAKE_*_FLAGS_${BUILD_TYPE} isn't really needed since we're setting the same value everywhere * functions sanitize variables differently from macros, darwin_add_embedded_builtin_libraries should be a macro otherwise it won't alter the variables. llvm-svn: 252618
* Rollback 252570 for further investigationXinliang David Li2015-11-101-2/+0
| | | | llvm-svn: 252575
* [CMake] Temporary workaround to support building builtins on darwin with a ↵Chris Bieneman2015-11-101-3/+18
| | | | | | | | toolchain that may not support all x86 and arm architectures. This is at least a little better than my first attempt. We still really need a way to do compile checks without linking. llvm-svn: 252572
* [PGO] Add LLVM main include dir to profile runtime buildXinliang David Li2015-11-101-0/+2
| | | | | | | | | | | | Runtime code implicitly depends on the defintions and const values defined in LLVM proper, but currently such dependency is made implicitly by duplicating code across two dirs. As part of the PGO cleanup effort, there will be changes to share common sources. This is a preparation patch to enable it (NFC). Differential Revision: http://reviews.llvm.org/D14487 llvm-svn: 252570
* Revert "[CMake] [macho_embedded] Check to make sure the compiler supports ↵Chris Bieneman2015-11-101-13/+1
| | | | | | | | the architectures before generating build targets" This commit reverts r252525. I was not really thinking about this fix properly. This doesn't work because it relys on try_compile checks which do a full compile & link. I'm going to put in a temporary solution as an interm step until we have a way to perform compiler checks without linking. llvm-svn: 252569
* [CMake] Don't pass -fPIC when compiling the darwin builtinsChris Bieneman2015-11-091-1/+1
| | | | | | This change makes CMake match autoconf. llvm-svn: 252547
* [CMake] Fixing a typo in variable name ARG_*->LIB_*Chris Bieneman2015-11-091-1/+1
| | | | llvm-svn: 252543
* [CMake] Removing extra underscore.Chris Bieneman2015-11-091-1/+1
| | | | | | Fixing a typo. llvm-svn: 252534
* [CMake] [Darwin] Don't generate lipo commands if we don't have libraries to ↵Chris Bieneman2015-11-091-12/+16
| | | | | | | | put into the fat archive. Not making sure there are thin libraries results in some difficult to diagnose build failures. This check should make those build failures go away. llvm-svn: 252527
* [CMake] [macho_embedded] Check to make sure the compiler supports the ↵Chris Bieneman2015-11-091-1/+13
| | | | | | | | architectures before generating build targets If we don't check the compiler's capabilities we end up generating build targets that the compiler might not be able to build. llvm-svn: 252525
* [compiler-rt] [asan] Use same shadow offset for aarch64Adhemerval Zanella2015-11-094-18/+7
| | | | | | | | This patch makes ASAN for aarch64 use the same shadow offset for all currently supported VMAs (39 and 42 bits). The shadow offset is the same for 39-bit (36). llvm-svn: 252497
* CFI: try to make test/cfi/base-derived-destructor.cpp pass on WindowsHans Wennborg2015-11-091-1/+1
| | | | llvm-svn: 252468
* [tsan] Skip building libcxx_tsan on OS XKuba Brecka2015-11-091-1/+2
| | | | | | | | The TSan-instrumented version of libcxx doesn't even build on OS X at this point. Let's skip it from the OS X build for now, since most of TSan functionality doesn't depend on it. This will enable `check-tsan` to be run. Differential Revision: http://reviews.llvm.org/D14486 llvm-svn: 252455
* [PGO] Cleanup: fix function-data field namesXinliang David Li2015-11-082-10/+10
| | | | | | | | To make them the same as the common def in InstrProfData.inc. This is a preparation to make the runtime code to use the template as well. NFC llvm-svn: 252421
* [tsan] Turn lit test deadlocks into failures (OS X)Kuba Brecka2015-11-078-0/+8
| | | | | | | | Several tests currently deadlock when the lit test suite is run on OS X. Let's mark them as unsupported. Differential Revision: http://reviews.llvm.org/D14443 llvm-svn: 252402
OpenPOWER on IntegriCloud