llvm-project/compiler-rt/test/cfi
Roman Lebedev d45054dbd2 [ubsan] Re-commit: lit changes for lld testing, future lto testing.
Summary:
As discussed in https://github.com/google/oss-fuzz/issues/933,
it would be really awesome to be able to use ThinLTO for fuzzing.
However, as @kcc has pointed out, it is currently undefined (untested)
whether the sanitizers actually function properly with LLD and/or LTO.

This patch is inspired by the cfi test, which already do test with LTO
(and/or LLD), since LTO is required for CFI to function.

I started with UBSan, because it's cmakelists / lit.* files appeared
to be the cleanest. This patch adds the infrastructure to easily add
LLD and/or LTO sub-variants of the existing lit test configurations.

Also, this patch adds the LLD flavor, that explicitly does use LLD to link.
The check-ubsan does pass on my machine. And to minimize the [initial]
potential buildbot breakage i have put some restrictions on this flavour.

Please review carefully, i have not worked with lit/sanitizer tests before.

The original attempt, r319525 was reverted in r319526 due
to the failures in compiler-rt standalone builds.

Reviewers: eugenis, vitalybuka

Reviewed By: eugenis

Subscribers: #sanitizers, pcc, kubamracek, mgorny, llvm-commits, mehdi_amini, inglorion, kcc

Differential Revision: https://reviews.llvm.org/D39508

llvm-svn: 319575
2017-12-01 19:36:29 +00:00
..
cross-dso [cfi] Test cross-dso CFI on Android. 2017-10-16 18:03:11 +00:00
icall [cfi] Mark a test as unsupported on darwin. 2017-10-05 19:36:15 +00:00
CMakeLists.txt [cfi] Disable tests with lld on i386. 2017-10-05 22:07:21 +00:00
README.txt Add tests for non-virtual call checking. 2015-04-02 00:33:36 +00:00
anon-namespace.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
bad-cast.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
bad-split.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
base-derived-destructor.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
create-derivers.test [cfi] Add explicit -flto in create-derivers test. 2017-04-20 21:44:37 +00:00
lit.cfg [ubsan] Re-commit: lit changes for lld testing, future lto testing. 2017-12-01 19:36:29 +00:00
lit.site.cfg.in [ubsan] Re-commit: lit changes for lld testing, future lto testing. 2017-12-01 19:36:29 +00:00
multiple-inheritance.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
nvcall.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
overwrite.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
sibling.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
simple-fail.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
simple-pass.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
stats.cpp Enable PDB generation with lld in asan and cfi tests on Windows. 2017-11-17 19:49:41 +00:00
target_uninstrumented.cpp [sanitizer] Move %ld_flags_rpath_exe to common and use it in more tests. 2017-10-05 20:00:07 +00:00
two-vcalls.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
utils.h CFI: Update tests for various bit vector sizes following lowerbitsets optzns. 2015-07-29 18:12:45 +00:00
vdtor.cpp Use %run for running CFI tests 2017-10-02 10:21:26 +00:00
vtable-may-alias.cpp LowerTypeTests: Give imported symbols a type with size 0 so that they are not assumed not to alias. 2017-10-13 21:02:16 +00:00

README.txt

The tests in this directory use a common convention for exercising the
functionality associated with bit sets of different sizes. When certain
macros are defined the tests instantiate classes that force the bit sets
to be of certain sizes.

- B32 forces 32-bit bit sets.
- B64 forces 64-bit bit sets.
- BM forces memory bit sets.