Age | Commit message (Collapse) | Author |
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316720 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
LSan is functional on PPC64 Linux now, let's enable all tests.
One test required ppc specific changes: use_registers.cc.
Reviewers: eugenis
Subscribers: mgorny, llvm-commits
Differential Revision: https://reviews.llvm.org/D39316
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@316698 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
For consistency with asan, msan, tsan and ubsan.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@314048 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This doesn't fix the failing test. Leave in the comment and the
attribute, since the used attribute is still required.
This partially reverts commit r312824
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@312827 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
-dead_strip in ld64 strips weak interface symbols, which I believe
is most likely the cause of this test failure. Re-enable after marking the interface
function as used.
Reviewers: alekseyshl, kubamracek, kcc
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D37635
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@312824 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Remove the explicit i686 target that is completely duplicate to
the i386 target, with the latter being used more commonly.
1. The runtime built for i686 will be identical to the one built for
i386.
2. Supporting both -i386 and -i686 suffixes causes unnecessary confusion
on the clang end which has to expect either of them.
3. The checks are based on wrong assumption that __i686__ is defined for
all newer x86 CPUs. In fact, it is only declared when -march=i686 is
explicitly used. It is not available when a more specific (or newer)
-march is used.
Curious enough, if CFLAGS contain -march=i686, the runtime will be built
both for i386 and i686. For any other value, only i386 variant will be
built.
Differential Revision: https://reviews.llvm.org/D26764
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@311924 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
The required change in clang is being reverted because of the Android
build bot failure.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@311859 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Remove the explicit i686 target that is completely duplicate to
the i386 target, with the latter being used more commonly.
1. The runtime built for i686 will be identical to the one built for
i386.
2. Supporting both -i386 and -i686 suffixes causes unnecessary confusion
on the clang end which has to expect either of them.
3. The checks are based on wrong assumption that __i686__ is defined for
all newer x86 CPUs. In fact, it is only declared when -march=i686 is
explicitly used. It is not available when a more specific (or newer)
-march is used.
Curious enough, if CFLAGS contain -march=i686, the runtime will be built
both for i386 and i686. For any other value, only i386 variant will be
built.
Differential Revision: https://reviews.llvm.org/D26764
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@311842 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Set proper errno code on alloction failures and change valloc and
memalign implementations to satisfy their man-specified requirements.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@308063 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
An attempt to reland D34786 (which caused bot failres on Mac), now with
properly intercepted operators new() and delete().
LSan allocator used to always return nullptr on too big allocation requests
(the definition of "too big" depends on platform and bitness), now it
follows policy configured by allocator_may_return_null flag
Reviewers: eugenis
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D34845
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@306845 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This reverts commit r306624.
The committed test failed on various bots (e.g. on green dragon).
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@306644 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
LSan allocator used to always return nullptr on too big allocation requests
(the definition of "too big" depends on platform and bitness), now it
follows policy configured by allocator_may_return_null flag.
Reviewers: eugenis
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D34786
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@306624 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This is required for standalone LSan to work with libdispatch worker threads,
and is a slimmed down version of the functionality provided for ASan
in asan_mac.cc.
Re-commit of r305695 with use_stacks=0 to get around a racy lingering pointer.
Reviewers: alekseyshl, kubamracek, glider, kcc
Subscribers: mgorny, llvm-commits
Differential Revision: https://reviews.llvm.org/D34247
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@305732 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This reverts r305695
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@305712 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This is required for standalone LSan to work with libdispatch worker threads,
and is a slimmed down version of the functionality provided for ASan
in asan_mac.cc.
Reviewers: alekseyshl, kubamracek, glider, kcc
Subscribers: mgorny, llvm-commits
Differential Revision: https://reviews.llvm.org/D34247
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@305695 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
The test was meant for Darwin anyway, so I'm not even sure it's supposed
to run on Linux. If it was, then we need time to investigate, but since
the test is new, there's no point in reverting the whole patch because
of it.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@304010 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This required for any users who call exit() after creating
thread-specific data, as tls destructors are only called when
pthread_exit() or pthread_cancel() are used. This should also
match tls behavior on linux.
Getting the base address of the tls section is straightforward,
as it's stored as a section offset in %gs. The size is a bit trickier
to work out, as there doesn't appear to be any official documentation
or source code referring to it. The size used in this patch was determined
by taking the difference between the base address and the address of the
subsequent memory region returned by vm_region_recurse_64, which was
1024 * sizeof(uptr) on all threads except the main thread, where it was
larger. Since the section must be the same size on all of the threads,
1024 * sizeof(uptr) seemed to be a reasonable size to use, barring
a more programtic way to get the size.
1024 seems like a reasonable number, given that PTHREAD_KEYS_MAX
is 512 on darwin, so pthread keys will fit inside the region while
leaving space for other tls data. A larger size would overflow the
memory region returned by vm_region_recurse_64, and a smaller size
wouldn't leave room for all the pthread keys. In addition, the
stress test added here passes, which means that we are scanning at
least the full set of possible pthread keys, and probably
the full tls section.
Reviewers: alekseyshl, kubamracek
Subscribers: krytarowski, llvm-commits
Differential Revision: https://reviews.llvm.org/D33215
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@303887 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This reverts r303262, due to TSan buildbot breakages.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@303266 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This required for any users who call exit() after creating
thread-specific data, as tls destructors are only called when
pthread_exit() or pthread_cancel() are used. This should also
match tls behavior on linux.
Getting the base address of the tls section is straightforward,
as it's stored as a section offset in %gs. The size is a bit trickier
to work out, as there doesn't appear to be any official documentation
or source code referring to it. The size used in this patch was determined
by taking the difference between the base address and the address of the
subsequent memory region returned by vm_region_recurse_64, which was
1024 * sizeof(uptr) on all threads except the main thread, where it was
larger. Since the section must be the same size on all of the threads,
1024 * sizeof(uptr) seemed to be a reasonable size to use, barring
a more programtic way to get the size.
1024 seems like a reasonable number, given that PTHREAD_KEYS_MAX
is 512 on darwin, so pthread keys will fit inside the region while
leaving space for other tls data. A larger size would overflow the
memory region returned by vm_region_recurse_64, and a smaller size
wouldn't leave room for all the pthread keys. In addition, the
stress test added here passes, which means that we are scanning at
least the full set of possible pthread keys, and probably
the full tls section.
Reviewers: alekseyshl, kubamracek
Subscribers: krytarowski, llvm-commits
Differential Revision: https://reviews.llvm.org/D33215
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@303262 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
These tests don't fail consistently in all cases, but they
fail most of the time on the buildbots. Mark as UNSUPPORTED for now to
avoid buildbots failing due to XPASS.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@302920 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
These are causing buildbot failures, disable for now.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@302912 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Reviewers: kubamracek, alekseyshl
Subscribers: mgorny, llvm-commits
Differential Revision: https://reviews.llvm.org/D32191
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@302904 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary: Re-landing reverted D31995 with suppressions defined in D32303 and D32377.
Reviewers: eugenis
Subscribers: nemanjai, llvm-commits
Differential Revision: https://reviews.llvm.org/D32379
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@301048 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300933 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This reverts commit r300897.
Most LSan/ASan tests are failing on darwin bots.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300929 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary: Re-landing reverted D31995 with suppressions defined in D32303.
Reviewers: eugenis
Subscribers: nemanjai, llvm-commits
Differential Revision: https://reviews.llvm.org/D32314
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300903 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Reviewers: kubamracek, alekseyshl
Subscribers: mgorny, llvm-commits
Differential Revision: https://reviews.llvm.org/D32191
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300897 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This already appears to be the case in all .cc test files,
it was probably left out of the .c test files accidentally. Make it a global
default, instead of manually adding it to each individual test.
This is needed to force leak detection for Darwin tests, where leak detection
is disabled by default.
Reviewers: m.ostapenko, kubamracek, alekseyshl
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D32297
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300890 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This option is disabled by our other test suites, and will cause
failures when unit tests abort instead of failing with an error code.
Will also prevent the test suite from being too slow.
Reviewers: kubamracek, alekseyshl
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D32129
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300593 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Reviewers: kubamracek, alekseyshl
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D32131
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300592 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
These tests aren't supported on other platforms, move them
to their own directory.
Reviewers: kubamracek, alekseyshl
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D32034
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300247 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This reverts commit r300204. Breaks ASAN tests on PPC.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300237 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
With D31555 commited, looks like basic LSan functionality
works on PPC64. Time to enable LSan there.
Reviewers: eugenis
Subscribers: nemanjai, llvm-commits
Differential Revision: https://reviews.llvm.org/D31995
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300204 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This patch addresses pr32636. Enable lsan tests on ARM bots filtering out Thumb targets.
Tested locally on ARM Arndale board in two configurations:
1) CFLAGS="-march=armv7-a"
Testing Time: 37.57s
Expected Passes : 69
Unsupported Tests : 7
2) CFLAGS="-march=armv7-a -mthumb"
Testing Time: 0.16s
Unsupported Tests : 76
Differential Revision: https://reviews.llvm.org/D32007
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300194 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
I didn't pay enough attention to the patch I reverted, now I'm going to
hit it with a bigger hammer until we can understand what the problems
are.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300044 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This reverts commit r299957. It broke the Thumb bots. We need to make
sure why and maybe stop it from being tested on Thumb environments. But
for now, let's get the bots green.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@300042 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@299957 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This patch reapplies r299923 with typo fixed in BLX macros.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@299948 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
FAILED: lib/sanitizer_common/CMakeFiles/RTSanitizerCommon.arm.dir/sanitizer_linux.cc.o
lib/sanitizer_common/sanitizer_linux.cc:1340:24: error: invalid instruction
BLX(ip)
^
lib/sanitizer_common/sanitizer_linux.cc:1313:19: note: expanded from macro 'BLX'
# define BLX(R) "mov lr, pc; bx" #R "\n"
^
<inline asm>:6:13: note: instantiated into assembly here
mov lr, pc; bxip
^~~~
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@299943 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This patch enables LSan for arm Linux.
Differential Revision: https://reviews.llvm.org/D29586
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@299923 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Summary:
This test fails with a false negative due to an unrelated change.
Since we expect a number of false negatives on 32-bit lsan,
disable this test on linux-i386 and linux-i686.
Reviewers: kubamracek, m.ostapenko, kcc
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D31300
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@298847 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Differential Revision: https://reviews.llvm.org/D29628
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@294425 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@293644 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@293621 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
The missed clang part was committed at https://reviews.llvm.org/rL293609 thus
we can reenable LSan for x86 Linux.
Differential Revision: https://reviews.llvm.org/D28609
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@293610 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
Breaks tests on i686/Linux due to missing clang driver support:
error: unsupported option '-fsanitize=leak' for target 'i386-unknown-linux-gnu'
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@292844 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
People keep asking LSan to be available on 32 bit targets (e.g. https://github.com/google/sanitizers/issues/403)
despite the fact that false negative ratio might be huge (up to 85%). This happens for big real world applications
that may contain random binary data (e.g. browser), but for smaller apps situation is not so terrible and LSan still might be useful.
This patch adds initial support for x86 Linux (disabled by default), ARM32 is in TODO list.
We used this patch (well, ported to GCC) on our 32 bit mobile emulators and it worked pretty fine
thus I'm posting it here to initiate further discussion.
Differential Revision: https://reviews.llvm.org/D28609
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@292775 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
in lit tests
The Clang driver on macOS decides the deployment target based on various things, like your host OS version, the SDK version and some environment variables, which makes lit tests pass or fail based on your environment. Let's make sure we run all lit tests with `-mmacosx-version-min=${SANITIZER_MIN_OSX_VERSION}` (10.9 unless overriden).
Differential Revision: https://reviews.llvm.org/D26929
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@288186 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This patch replaces fprintf with print_address function in LSAN
tests. This is necessary because of different printing of pointers
in fprintf and sanitizer's print function.
Differential Revision: https://reviews.llvm.org/D26084.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@286816 91177308-0d34-0410-b5e6-96231b3b80d8
|
|
This patch replaces fprintf with print_address function
in LSAN tests. This is necessary because of different
printing of pointers in fprintf and sanitizer's print
function. Differential Revision: https://reviews.llvm.org/D25270.
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@284722 91177308-0d34-0410-b5e6-96231b3b80d8
|