summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-11-09[msan] Add context argument into GetStackTraceVitaly Buka
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317773 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-09[lsan] Add "static" to internal functionVitaly Buka
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317772 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-09[libFuzzer] allow merge to resume after being preempted Kostya Serebryany
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317767 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-09ubsan: Allow programs to use setenv to configure ubsan_standalone.Peter Collingbourne
Previously ubsan_standalone used the GetEnv function to read the environment variables UBSAN_OPTIONS and UBSAN_SYMBOLIZER_PATH. The problem with GetEnv is that it does not respect changes to the environment variables made using the libc setenv function, which prevents clients from setting environment variables to configure ubsan before loading ubsan-instrumented libraries. The reason why we have GetEnv is that some runtimes need to read environment variables while they initialize using .preinit_array, and getenv does not work while .preinit_array functions are being called. However, it is unnecessary for ubsan_standalone to initialize that early. So this change switches ubsan_standalone to using getenv and removes the .preinit_array entry. The static version of the runtime still ends up being initialized using a C++ constructor that exists to support the shared runtime. Differential Revision: https://reviews.llvm.org/D39827 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317757 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-09[libFuzzer] mechanically simplify a test, NFCKostya Serebryany
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317756 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-09[libFuzzer] fix a test (and hopefully, the bot)Kostya Serebryany
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317749 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-09[libFuzzer] allow user to specify the merge control fileKostya Serebryany
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317747 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08[Sanitizers, CMake] Also use version script for libclang_rt.asan-i386.soEvgeniy Stepanov
When building LLVM on x86_64-pc-linux-gnu (Fedora 25) with the bundled gcc 6.4.1 which uses gld 2.26.1-1.fc25, the dynamic/Asan-i386-calls-Dynamic-Test and dynamic/Asan-i386-inline-Dynamic-Test tests failed to link with /usr/bin/ld: /var/scratch/gcc/llvm/dist/lib/clang/6.0.0/lib/linux/libclang_rt.asan-i386.so: fork: invalid version 21 (max 0) /var/scratch/gcc/llvm/dist/lib/clang/6.0.0/lib/linux/libclang_rt.asan-i386.so: error adding symbols: Bad value I tried building with a self-compiled gcc 7.1.0 using gld 2.28, but the error remained. It seems the error has been hit before (cf. https://reviews.llvm.org/rL314085), but no real explanation has been found. However, the problem goes away when linking the i386 libclang_rt.asan with a version script just like every other variant is. Not using the version script in this single case dates back to the initial introduction of the version script in r236551, but this change was just checked in without any explanation AFAICT. Since I've not found any other workaround and no reason for not always using the version script, I propose to do so. Tested on x86_64-pc-linux-gnu. Patch by Rainer Orth. Differential Revision: https://reviews.llvm.org/D39795 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317738 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08Correct atexit(3) support in TSan/NetBSDKamil Rytarowski
Summary: The NetBSD specific implementation of cxa_atexit() does not preserve the 2nd argument if dso is equal to NULL. Changes: - Split paths of handling intercepted __cxa_atexit() and atexit(3). This affects all supported Operating Systems. - Add a local stack-like structure to hold the __cxa_atexit() context. atexit(3) is documented in the C standard as calling callback from the earliest to the oldest entry. This path also fixes potential ABI problem of passing an argument to a function from the atexit(3) callback mechanism. - Add new test to ensure LIFO style of atexit(3) callbacks: atexit3.cc Proposal to change the behavior of __cxa_atexit() in NetBSD has been rejected. With the above changes TSan/NetBSD with the current tsan_interceptors.cc can bootstrap into operation. Sponsored by <The NetBSD Foundation> Reviewers: vitalybuka, dvyukov, joerg, kcc, eugenis Reviewed By: dvyukov Subscribers: kubamracek, llvm-commits, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D39619 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317735 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08[ThinLTO] New test needs to require LTOTeresa Johnson
Fix buildbot failures: http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux/builds/5262/steps/annotate/logs/stdio git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317728 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08[ThinLTO] Ensure sanitizer passes are runTeresa Johnson
Recommit new test as linux-only. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317723 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08Revert "[ThinLTO] Ensure sanitizer passes are run"Teresa Johnson
This reverts commit r317715. It failed a Windows buildbot since ThinLTO is presumably not supported, leading to a corrupt file error on the object file: http://lab.llvm.org:8011/builders/sanitizer-windows/builds/19395/steps/run%20check-asan/logs/stdio Will re-commit the new ThinLTO part of the test to a linux only test file. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317717 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08[ThinLTO] Ensure sanitizer passes are runTeresa Johnson
Summary: Test fix to pass manager for ThinLTO. Depends on D39565. Reviewers: pcc Subscribers: kubamracek, mehdi_amini, llvm-commits, inglorion Differential Revision: https://reviews.llvm.org/D39566 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317715 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08Implement flock for Windows in compiler-rtMarco Castelluccio
Summary: This patch implements flock for Windows, needed to make gcda writing work in a multiprocessing scenario. Fixes https://bugs.llvm.org/show_bug.cgi?id=34923. Reviewers: zturner Reviewed By: zturner Subscribers: rnk, zturner, llvm-commits Differential Revision: https://reviews.llvm.org/D38891 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317705 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08[sanitizer] Add Scudo to the sanitizer lint checks.Kostya Kortchinsky
Summary: Scudo abides by the coding style enforced by the sanitizer_common linter, but as of right now, it's not linter-enforced. Add Scudo to the list of directories checked by check_lint.sh. Also: fixes some linter errors found after getting this running. Reviewers: cryptoad Reviewed By: cryptoad Subscribers: llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D39757 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317699 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08Always use prctl(PR_SET_PTRACER)Sylvestre Ledru
Summary: Sufficiently old Linux kernel headers don't provide the PR_SET_PTRACER, but we can still call prctl with it if the runtime kernel is newer. Even if it's not, prctl will only return EINVAL. Patch by Mike Hommey <mh-llvm@glandium.org> Reviewers: eugenis Reviewed By: eugenis Subscribers: sylvestre.ledru, cfe-commits, kubamracek Differential Revision: https://reviews.llvm.org/D39717 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317668 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08Revert "[scudo] Make getNumberOfCPUs Fuchsia compliant"Reid Kleckner
This reverts commit r317604. Android doesn't have cpu_set_t. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317655 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-08[sanitizer] Asm implementation of syscall() for arm32.Evgeniy Stepanov
Summary: These will be used in an ifunc resolver, when the binary may not be completely relocated, and syscall() function from libc could not be used. Reviewers: dvyukov, vitalybuka Subscribers: aemerson, kubamracek, javed.absar, llvm-commits, kristof.beyls Differential Revision: https://reviews.llvm.org/D39701 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317640 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-07(NFC) Rename GetMax{,User}VirtualAddress.Evgeniy Stepanov
Future change will introduce GetMaxVirtualAddress that will not take the kernel area into account. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317638 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-07[sanitizer] Fix sanitizer_common compile errors on gcc trunkVitaly Buka
Summary: When testing a merge of compiler-rt r304709 into gcc trunk on x86-64-pc-linux-gnu, I ran into two compile errors: sanitizer_common/sanitizer_symbolizer_libbacktrace.cc:96:73: error: no matching function for call to '__sanitizer::AddressInfo::FillModuleInfo(char*&, __sanitizer::uptr&)' All other files in sanitizer_common (with the exception of sanitizer_malloc_mac.inc which is special) include sanitizer_platform.h without directory name. Patch by Mike Jongen Reviewers: kcc, vitalybuka Reviewed By: kcc Subscribers: kubamracek, fedor.sergeev, llvm-commits Differential Revision: https://reviews.llvm.org/D33933 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317608 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-07[scudo] Make getNumberOfCPUs Fuchsia compliantKostya Kortchinsky
Summary: This change allows Fuchsia to boot properly using the Scudo allocator. Reviewers: cryptoad, alekseyshl, krytarowski Reviewed By: cryptoad, krytarowski Subscribers: krytarowski, kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D39490 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317604 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-07[WebAssembly] Include GENERIC_TF_SOURCES in wasm buildsSam Clegg
Differential Revision: https://reviews.llvm.org/D39748 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317601 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-07tsan: allow usage of global vars with ctors in interceptorsDmitry Vyukov
We allow usage of global/per-thread data with non-trivial ctors/dtors throughout tsan code base by placing all global/per-thread data into Context/ThreadState and then explicitly constructing them with placement new. This greatly simplifies code by restricting the "linker initialized plague" to only these 2 objects. Do the same for interceptors data. This allows to use Vector instead of bunch of hand-written code in: https://reviews.llvm.org/D39619 Reviewed in: https://reviews.llvm.org/D39721 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317587 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-07Update sanitizer_allocator to use new API.Kostya Kortchinsky
Summary: Update sanitizer_allocator to use new API. Second patch in a series. First patch https://reviews.llvm.org/D39072 Updates MmapNoAccess / MmapFixed call sites in the saniziter_allocator to use the new Init/Map APIs instead. Reviewers: alekseyshl, cryptoad, phosek, mcgrathr, dvyukov Reviewed By: alekseyshl, cryptoad Subscribers: dvyukov, mcgrathr, kubamracek Differential Revision: https://reviews.llvm.org/D38592 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317586 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-06[LSan] Detect dynamic loader by its base address.Alex Shlyapnikov
Summary: Relanding D38600, which was reverted due to various PPC bot failures. If it breaks something again, please provide some pointers to broken bots, not just revert it, otherwise it's very hard to reason what's wrong with this commit. Whenever possible (Linux + glibc 2.16+), detect dynamic loader module by its base address, not by the module name matching. The current name matching approach fails on some configurations. Reviewers: eugenis Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D39275 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317512 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-06[Sanitizers] Check pthread_setcancel{state|type} interceptor arguments for ↵Alex Shlyapnikov
!= nullptr. Summary: According to man, pthread_setcancelstate's oldstate and pthread_setcanceltype's oldtype parameters can be nullptr. Check these parameters for != nullptr before attempting to access their shadow memory. Reviewers: dvyukov Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D39626 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317494 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-04Fix CMake definitions of tsan runtime to make it installed by ↵Mehdi Amini
"install-compiler-rt" Summary: The PARENT_TARGET was correctly set under APPLE but not under linux. Reviewers: kubamracek, samsonov Subscribers: dberris, mgorny, llvm-commits Differential Revision: https://reviews.llvm.org/D39621 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317391 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-03[scudo] Rearrange #include orderKostya Kortchinsky
Summary: To be compliant with https://llvm.org/docs/CodingStandards.html#include-style, system headers have to come after local headers. Reviewers: alekseyshl Reviewed By: alekseyshl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39623 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317390 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-03[Sanitizers] Call NanoTime() conditionally.Alex Shlyapnikov
Summary: Call NanoTime() in primary 64 bit allocator only when necessary, otherwise the unwarranted syscall causes problems in sandbox environments. ReleaseToOSIntervalMs() conditional allows them to turn the feature off with allocator_release_to_os_interval_ms=-1 flag. Reviewers: eugenis Subscribers: kubamracek, llvm-commits Differential Revision: https://reviews.llvm.org/D39624 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317386 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-03Late fixup in _lwp_exit on TSan/NetBSDKamil Rytarowski
Call DestroyThreadState() before REAL(_lwp_exit)(); This variation is less racy. Sponsored by <The NetBSD Foundation> git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317369 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-03Correct detection of a thread terminationKamil Rytarowski
Summary: Stop using the Linux solution with pthread_key_create(3). This approach does not work on NetBSD, because calling the thread destructor is not the latest operation on a POSIX thread entity. NetBSD's libpthread still calls at least pthread_mutex_lock and pthread_mutex_unlock. Detect _lwp_exit(2) call as it is really the latest operation called from a detaching POSIX thread. This resolves one set of crashes observed in the Thread Sanitizer execution. Sponsored by <The NetBSD Foundation> Reviewers: joerg, kcc, vitalybuka, dvyukov, eugenis Reviewed By: vitalybuka Subscribers: llvm-commits, kubamracek, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D39618 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317363 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-03Disable detection of on_exit()/TSan on NetBSDKamil Rytarowski
Summary: NetBSD does not ship with on_exit() function. Introduce TSAN_MAYBE_INTERCEPT_ON_EXIT. It looks like this addition fixes build for Darwin. Sponsored by <The NetBSD Foundation> Reviewers: vitalybuka, joerg, eugenis, dvyukov, kcc Reviewed By: vitalybuka Subscribers: llvm-commits, kubamracek, #sanitizers Tags: #sanitizers Differential Revision: https://reviews.llvm.org/D39617 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317361 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-02[fuzzer] Fix nested mallocsVitaly Buka
Summary: Nested mallocs are possible with internal symbolizer. Reviewers: kcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39397 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317186 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-01[fuzzer] Script to detect unbalanced allocation in -trace_malloc outputVitaly Buka
Reviewers: kcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39466 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317119 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-01[scudo] Fix standlone build -lrt requirementKostya Kortchinsky
Summary: The split in D39461 introduced separate C++ flags, but `cxx_flags` needs `-lrt` as well for the standalone build. Reviewers: alekseyshl Reviewed By: alekseyshl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39497 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317103 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-01[scudo] Implement stricter separation of C vs C++Kostya Kortchinsky
Summary: Initially, Scudo had a monolithic design where both C and C++ functions were living in the same library. This was not necessarily ideal, and with the work on -fsanitize=scudo, it became more apparent that this needed to change. We are splitting the new/delete interceptor in their own C++ library. This allows more flexibility, notably with regard to std::bad_alloc when the work is done. This also allows us to not link new & delete when using pure C. Additionally, we add the UBSan runtimes with Scudo, in order to be able to have a -fsanitize=scudo,undefined in Clang (see work in D39334). The changes in this patch: - split the cxx specific code in the scudo cmake file into a new library; (remove the spurious foreach loop, that was not necessary) - add the UBSan runtimes (both C and C++); - change the test cmake file to allow for specific C & C++ tests; - make C tests pure C, rename their extension accordingly. Reviewers: alekseyshl Reviewed By: alekseyshl Subscribers: srhines, mgorny, llvm-commits Differential Revision: https://reviews.llvm.org/D39461 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317097 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-01[fuzzer] Fix threaded stack printingVitaly Buka
Reviewers: kcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39397 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317071 91177308-0d34-0410-b5e6-96231b3b80d8
2017-11-01Revert "[fuzzer] Fix threaded stack printing and nested mallocs"Vitaly Buka
Fails on darwin Revert "[fuzzer] Script to detect unbalanced allocation in -trace_malloc output" Needs previous one. This reverts commit r317034, r317036. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317061 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-31[fuzzer] Script to detect unbalanced allocation in -trace_malloc outputVitaly Buka
Reviewers: kcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39466 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317036 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-31[fuzzer] Fix threaded stack printing and nested mallocsVitaly Buka
Summary: Nested mallocs are possible with internal symbolizer. Reviewers: kcc Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39397 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@317034 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-30[sanitizer][Fuchsia] Add a missing semicolonPetr Hosek
Differential Revision: https://reviews.llvm.org/D39433 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316959 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-30Fix warning + death test + failing test on Windows (D39072).Kostya Kortchinsky
Summary: Fixes https://reviews.llvm.org/D39072 Reviewers: cryptoad Reviewed By: cryptoad Subscribers: kubamracek Differential Revision: https://reviews.llvm.org/D39427 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316943 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-30[sanitizer] Fixing an error introduced in D39072Kostya Kortchinsky
Summary: This should fix the Windows bots after D39072. Reviewers: alekseyshl, flowerhack Reviewed By: flowerhack Subscribers: llvm-commits, kubamracek Differential Revision: https://reviews.llvm.org/D39426 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316937 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-30Introduce ReservedAddressRange to sanitizer_common.Kostya Kortchinsky
Summary: Fixed version of https://reviews.llvm.org/D38437 (fixes Win/Fuchsia failures). Creating a new revision, since the old one was getting a bit old/crowded. In Fuchsia, MmapNoAccess/MmapFixedOrDie are implemented using a global VMAR, which means that MmapNoAccess can only be called once. This works for the sanitizer allocator but *not* for the Scudo allocator. Hence, this changeset introduces a new ReservedAddressRange object to serve as the new API for these calls. In this changeset, the object still calls into the old Mmap implementations. The next changeset two changesets will convert the sanitizer and scudo allocators to use the new APIs, respectively. (ReservedAddressRange will replace the SecondaryHeader in Scudo.) Finally, a last changeset will update the Fuchsia implementation. Reviewers: alekseyshl, cryptoad, phosek Reviewed By: alekseyshl, cryptoad Subscribers: kubamracek Differential Revision: https://reviews.llvm.org/D39072 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316934 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-30Fix clang warnings in winasan codeReid Kleckner
There are two instances of -Wcast-qual and one of -Wsign-compare. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316930 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-30[asan] Intercept heap routines in VS2010 CRTReid Kleckner
Users have requested that we add it to the list: https://github.com/google/sanitizers/issues/864 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316929 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-28[XRay] [compiler-rt] fix build by including errno.h into FDR modeMartin Pelikan
The build got broken after D39277 (and rL316816) deleted <cerrno>. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316821 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-27[XRay][compiler-rt] Remove more STL dependenices from FDR modeDean Michael Berris
Summary: This change removes dependencies on STL types: - std::aligned_storage -- we're using manually-aligned character buffers instead for metadata and function records. - std::tuple -- use a plain old struct instead. This is an incremental step in removing all STL references from the compiler-rt implementation of XRay (llvm.org/PR32274). Reviewers: dblaikie, pelikan, kpw Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39277 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316816 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-27[scudo] Allow to specify the maximum number of TSDs at compile timeKostya Kortchinsky
Summary: This introduces `SCUDO_MAX_CACHES` allowing to define an upper bound to the number of `ScudoTSD` created in the Shared TSD model (by default 32U). This name felt clearer than `SCUDO_MAX_TSDS` which is technically what it really is. I am opened to suggestions if that doesn't feel right. Additionally change `getNumberOfCPUs` to return a `u32` to be more consistent. Reviewers: alekseyshl Reviewed By: alekseyshl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D39338 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316788 91177308-0d34-0410-b5e6-96231b3b80d8
2017-10-27[LSan] Disable a couple of failing tests on PPC64 (pending investigation).Alex Shlyapnikov
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316720 91177308-0d34-0410-b5e6-96231b3b80d8