Age | Commit message (Collapse) | Author |
|
This prevents gold from printing a warning when trying to export
these symbols via the asan dynamic list after ThinLTO promotes them
from private symbols to external symbols with hidden visibility.
Differential Revision: https://reviews.llvm.org/D49498
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@337428 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
The test case fails on the big-endian PPC bot, probably because PowerPC
uses function descriptors. More over other architectures don't support
NX mappings. (This test case was not being exercised prior to r336633.)
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@336714 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Processors before z14 don't support non-execute protection,
so they will start execution random memory contents, causing
the test to randomly fail or succeed.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@336705 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Original patch by Kuba Mracek
The %T lit expansion expands to a common directory shared between all
the tests in the same directory, which is unexpected and unintuitive,
and more importantly, it's been a source of subtle race conditions and
flaky tests. In https://reviews.llvm.org/D35396, it was agreed that it
would be best to simply ban %T and only keep %t, which is unique to each
test. When a test needs a temporary directory, it can just create one
using mkdir %t.
This patch removes %T in compiler-rt.
Differential Revision: https://reviews.llvm.org/D48618
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@336661 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
The failure in https://github.com/google/sanitizers/issues/981 is flaky.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335941 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
https://github.com/google/sanitizers/issues/981
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335937 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
NDK r16 provides glob.h, which makes this test pass.
Supporting different test outcomes depending on the version of NDK
add unnecessary complexity to the test harness. IMHO, it's OK to require
the latest stable release.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335935 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This change adds a support for multiarch style runtimes layout, so in
addition to the existing layout where runtimes get installed to:
lib/clang/$version/lib/$os
Clang now allows runtimes to be installed to:
lib/clang/$version/$target/lib
This also includes libc++, libc++abi and libunwind; today those are
assumed to be in Clang library directory built for host, with the
new layout it is possible to install libc++, libc++abi and libunwind
into the runtime directory built for different targets.
The use of new layout is enabled by setting the
LLVM_ENABLE_RUNTIME_TARGET_DIR CMake variable and is supported by both
projects and runtimes layouts. The runtimes CMake build has been further
modified to use the new layout when building runtimes for multiple
targets.
Differential Revision: https://reviews.llvm.org/D45604
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335809 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
On Darwin/x86_64, asan may report the crashing line of NullDeref as line
19 (i.e the closing brace of the function), whereas on other targets we
see line 15 ("ptr[10]++").
The optimized debug info here isn't reliable enough to check.
rdar://problem/41526369
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335747 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
On some ARM platforms this test depends on debug locations being
present on constant materialization code, which was eliminated in
r335497.
Relax the test to allow two outcomes: the backtrace either contains the
right line numbers, or no line numbers.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335741 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
There's more platforms than just "ios" and "iossim" that we should support, and adding more lit config variables for each platform isn't great. Let's generalize and have a single value that determines what the platform under test is.
Differential Revision: https://reviews.llvm.org/D48309
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335123 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335089 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335087 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
"echo data" didn't work because %run on android executes test on the device
when lit shell command on the host system.
https://github.com/google/sanitizers/issues/952
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334883 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Reviewers: Lekensteyn
Reviewed By: Lekensteyn
Subscribers: srhines, kubamracek, llvm-commits
Differential Revision: https://reviews.llvm.org/D48186
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334866 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Glob patterns seem unsupported for commands executed by the emulated
shell (LIT_USE_INTERNAL_SHELL=1). Disable the test while that is being
addressed (a workaround such as "cd a-*" also does not work).
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334719 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Error messages for dlsym used to be stored on the stack, but since
commit 2449ae7b ("ld.so: Introduce struct dl_exception") in glibc 2.27
these are now stored on the heap (and thus use the dlsym alloc pool).
Messages look like "undefined symbol: __isoc99_printf\0/path/to/a.out".
With many missing library functions and long object paths, the pool is
quickly exhausted. Implement a simple mechanism to return freed memory
to the pool (clear it in case it is used for calloc).
Fixes https://github.com/google/sanitizers/issues/957
Reviewed By: vitalybuka
Differential Revision: https://reviews.llvm.org/D47995
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334703 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
It seems to be passing, at least on the bots I've seen.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334626 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
aarch64/aosp_marlin-userdebug/OPR4.170623.016] builder unexpectedly
failed the fgets test (`assertion "fp" failed`). macOS unexpectedly
passes the fputs test without triggering ASAN.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334558 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Some systems (Android) might not have /etc/passwd. Fixes r334450.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334487 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Add fgets, fputs and puts to sanitizer_common. This adds ASAN coverage
for these functions, extends MSAN support from fgets to fputs/puts and
extends TSAN support from puts to fputs.
Fixes: https://github.com/google/sanitizers/issues/952
Reviewed By: vitalybuka
Differential Revision: https://reviews.llvm.org/D46545
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334450 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Add allocator_returns_null.cc test to sanitizer_common and
remove all sanitizer-specific ones except:
- HWASan is not covered by sanitizer_common
- TSan allocator does not have comprehensive error reporting yet
Reviewers: vitalybuka
Subscribers: kubamracek, delcypher, #sanitizers, llvm-commits
Differential Revision: https://reviews.llvm.org/D47971
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334433 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Now all sanitizers with improved allocator error reporting are covered
by these common tests.
Also, add pvalloc-specific checks to LSan.
HWASan is not covered by sanitizer_common, hence its own pvalloc
and other allocator tests.
Reviewers: vitalybuka
Subscribers: srhines, kubamracek, delcypher, #sanitizers, llvm-commits
Differential Revision: https://reviews.llvm.org/D47970
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334424 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
PR22682. Bug in gold was fixed 3 years ago.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334319 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Move the corresponding tests to the common folder (as all of the
sanitizer allocators will support this feature soon) and add the checks
specific to aligned_alloc to ASan and LSan allocators.
Reviewers: vitalybuka
Subscribers: srhines, kubamracek, delcypher, #sanitizers, llvm-commits
Differential Revision: https://reviews.llvm.org/D47924
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334316 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Address failures exhibited by ARMv8 bot in Thumb mode:
- Fix logic for fast unwinding support (i.e feature is not available for Thumb)
- Fix Unsupported and Requires rules to handle armv8 as well as soft and hard
float targets
- Un-xfail passing tests
Differential Revision: https://reviews.llvm.org/D47575
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@333729 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
The dlopen(3) features on NetBSD are in libc.
Sponsored by <The NetBSD Foundation>
Reviewers: joerg, vitalybuka, kcc
Reviewed By: vitalybuka
Subscribers: kubamracek, llvm-commits, #sanitizers
Tags: #sanitizers
Differential Revision: https://reviews.llvm.org/D46713
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@332790 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
r328775) for all platforms.
Given that this is the second occurance of this problem it seemed worth
fixing this problem in a more generic way. r328775 has been reverted and
now a substitution `%linux_static_libstdcplusplus` has been provided.
This substitution expands to Clang driver arguments to use a static
libstdc++ on Linux and on all other platforms it expands to nothing.
The `asan/TestCases/throw_invoke_test.cc` and
`test/tsan/static_init6.cc` test cases now use this substitution.
rdar://problem/39948818
Differential Revision: https://reviews.llvm.org/D46401
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@332254 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Otherwise LLD will not align the .ASAN$GA section start, and
&__asan_globals + 1 will not be the start of the next real ASan global
metadata in .ASAN$GL.
We discovered this issue when attempting to use LLD on Windows in
Chromium: https://crbug.com/837090
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@330990 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Although sprintf is not intercepted on Windows, this test can pass
if sprintf calls memmove, which is intercepted, so we can't XFAIL it.
Differential Revision: https://reviews.llvm.org/D45894
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@330469 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
IsStackOverflow only treats accesses within 512 bytes of SP as stack-overflow. This should really be the size of a page instead.
The scariness_score_test.cc triggers stack overflow with frames that are even larger than a page, which can also trigger a fault that will not be recognized as stack-overflow. Let's just use smaller frames.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@329980 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@329688 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Under some circumstances (that I haven't dug further into), the first stack
frame for the test looks like:
`#0 0x4e6038 in __interceptor_memalign.localalias.1 ...compiler-rt/lib/asan/asan_malloc_linux.cc:113`
which isn't matched by the current CHECK.
Expand the CHECK to match aligned_alloc or memalign. Hopefully this should fix
the PowerPC issue as well, otherwise we'll bring back the FIXME.
Reviewers: alekseyshl
Reviewed By: alekseyshl
Subscribers: srhines, kubamracek, delcypher, #sanitizers, llvm-commits
Differential Revision: https://reviews.llvm.org/D45281
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@329226 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
As many other ASan tests already, has to disable these failing tests on
arm, armhf and aarch64 configs.
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328849 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
and the general version to avoid use of libstdc++ on non-Linux
platforms.
This is motivated by the fact that using `libstdc++` is deprecated on
Darwin and maybe removed some day.
Differential Revision: https://reviews.llvm.org/D44733
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328775 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328753 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328742 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This check "CHECK: {{#0 0x.* in .*aligned_alloc}}" fails on ppc64be, gcc
build. Disabling the test for gcc for now.
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328741 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328734 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
aligned_alloc is not always defined in headers.
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328726 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
Currently many allocator specific errors (OOM, for example) are reported as
a text message and CHECK(0) termination, not stack, no details, not too
helpful nor informative. To improve the situation, ASan detailed errors were
defined and reported under the appropriate conditions.
Issue: https://github.com/google/sanitizers/issues/887
Reviewers: eugenis
Subscribers: kubamracek, delcypher, #sanitizers, llvm-commits
Differential Revision: https://reviews.llvm.org/D44404
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328722 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Replacing vfork with fork results in significant slowdown of certain
apps (in particular, memcached).
This reverts r327752.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@328600 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
vfork is not ASan-friendly because it modifies stack shadow in the
parent process address space. While it is possible to compensate for that with, for example,
__asan_handle_no_return before each call to _exit or execve and friends, simply replacing
vfork with fork looks like by far the easiest solution.
Posix compliant programs can not detect the difference between vfork and fork.
Fixes https://github.com/google/sanitizers/issues/925
Reviewers: kcc, vitalybuka
Subscribers: kubamracek, llvm-commits
Differential Revision: https://reviews.llvm.org/D44587
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327752 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Reviewers: kcc, alekseyshl, vitalybuka
Subscribers: kubamracek, llvm-commits
Differential Revision: https://reviews.llvm.org/D44339
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327337 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
by explicitly listing where we expect this test to work.
Because this test invokes undefined behaviour all sorts of things
can happen (e.g. crash, or on some bots asan manages to catch
something). The test seems to pass okay on Darwin (x86_64/x86_64/i386)
and on Linux (x86_64/i386) so explicitly require one of these platforms
to run the test.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327185 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
x86_64 and x86_64H (and not in the iOS simulator) where it seems
to work. We need to properly fix the test when time permits.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327122 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
doesn't know how to handle suppression files.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327091 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327081 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327080 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
`strcpy()`, `strncpy()`, `strcat()`, and `strncat()`.
rdar://problem/35576899
Differential Revision: https://reviews.llvm.org/D43702
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@327068 91177308-0d34-0410-b5e6-96231b3b80d8
|