summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt3
-rw-r--r--lib/asan/CMakeLists.txt6
-rw-r--r--lib/asan/lit_tests/CMakeLists.txt65
-rw-r--r--test/CMakeLists.txt3
-rw-r--r--test/asan/CMakeLists.txt64
-rw-r--r--test/asan/GenericConfig/lit.site.cfg.in (renamed from lib/asan/lit_tests/GenericConfig/lit.site.cfg.in)4
-rw-r--r--test/asan/TestCases/Darwin/asan_gen_prefixes.cc (renamed from lib/asan/lit_tests/TestCases/Darwin/asan_gen_prefixes.cc)0
-rw-r--r--test/asan/TestCases/Darwin/interface_symbols_darwin.c (renamed from lib/asan/lit_tests/TestCases/Darwin/interface_symbols_darwin.c)2
-rw-r--r--test/asan/TestCases/Darwin/lit.local.cfg (renamed from lib/asan/lit_tests/TestCases/Darwin/lit.local.cfg)0
-rw-r--r--test/asan/TestCases/Darwin/malloc_set_zone_name-mprotect.cc (renamed from lib/asan/lit_tests/TestCases/Darwin/malloc_set_zone_name-mprotect.cc)0
-rw-r--r--test/asan/TestCases/Darwin/malloc_zone-protected.cc (renamed from lib/asan/lit_tests/TestCases/Darwin/malloc_zone-protected.cc)0
-rw-r--r--test/asan/TestCases/Darwin/reexec-insert-libraries-env.cc (renamed from lib/asan/lit_tests/TestCases/Darwin/reexec-insert-libraries-env.cc)0
-rw-r--r--test/asan/TestCases/Darwin/unset-insert-libraries-on-exec.cc (renamed from lib/asan/lit_tests/TestCases/Darwin/unset-insert-libraries-on-exec.cc)0
-rw-r--r--test/asan/TestCases/Helpers/blacklist-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/blacklist-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/echo-env.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/echo-env.cc)0
-rw-r--r--test/asan/TestCases/Helpers/init-order-atexit-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/init-order-atexit-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/init-order-pthread-create-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/init-order-pthread-create-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-blacklist-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-blacklist-extra2.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist-extra2.cc)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-blacklist.txt (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist.txt)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-bug-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-bug-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-bug-extra2.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-bug-extra2.cc)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-constexpr-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-constexpr-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/initialization-nobug-extra.cc (renamed from lib/asan/lit_tests/TestCases/Helpers/initialization-nobug-extra.cc)0
-rw-r--r--test/asan/TestCases/Helpers/lit.local.cfg (renamed from lib/asan/lit_tests/TestCases/Helpers/lit.local.cfg)0
-rw-r--r--test/asan/TestCases/Linux/asan_prelink_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/asan_prelink_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/clone_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/clone_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/coverage.cc (renamed from lib/asan/lit_tests/TestCases/Linux/coverage.cc)0
-rw-r--r--test/asan/TestCases/Linux/function-sections-are-bad.cc (renamed from lib/asan/lit_tests/TestCases/Linux/function-sections-are-bad.cc)0
-rw-r--r--test/asan/TestCases/Linux/glob.cc (renamed from lib/asan/lit_tests/TestCases/Linux/glob.cc)0
-rw-r--r--test/asan/TestCases/Linux/glob_test_root/aa (renamed from lib/asan/lit_tests/TestCases/Linux/glob_test_root/aa)0
-rw-r--r--test/asan/TestCases/Linux/glob_test_root/ab (renamed from lib/asan/lit_tests/TestCases/Linux/glob_test_root/ab)0
-rw-r--r--test/asan/TestCases/Linux/glob_test_root/ba (renamed from lib/asan/lit_tests/TestCases/Linux/glob_test_root/ba)0
-rw-r--r--test/asan/TestCases/Linux/globals-gc-sections.cc (renamed from lib/asan/lit_tests/TestCases/Linux/globals-gc-sections.cc)0
-rw-r--r--test/asan/TestCases/Linux/heap-overflow-large.cc (renamed from lib/asan/lit_tests/TestCases/Linux/heap-overflow-large.cc)0
-rw-r--r--test/asan/TestCases/Linux/heavy_uar_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/initialization-bug-any-order.cc (renamed from lib/asan/lit_tests/TestCases/Linux/initialization-bug-any-order.cc)0
-rw-r--r--test/asan/TestCases/Linux/interception_failure_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/interception_failure_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/interception_malloc_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/interception_malloc_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/interception_readdir_r_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/interception_readdir_r_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/interception_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/interception_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/interface_symbols_linux.c (renamed from lib/asan/lit_tests/TestCases/Linux/interface_symbols_linux.c)2
-rw-r--r--test/asan/TestCases/Linux/lit.local.cfg (renamed from lib/asan/lit_tests/TestCases/Linux/lit.local.cfg)0
-rw-r--r--test/asan/TestCases/Linux/malloc-in-qsort.cc (renamed from lib/asan/lit_tests/TestCases/Linux/malloc-in-qsort.cc)0
-rw-r--r--test/asan/TestCases/Linux/malloc_delete_mismatch.cc (renamed from lib/asan/lit_tests/TestCases/Linux/malloc_delete_mismatch.cc)0
-rw-r--r--test/asan/TestCases/Linux/overflow-in-qsort.cc (renamed from lib/asan/lit_tests/TestCases/Linux/overflow-in-qsort.cc)0
-rw-r--r--test/asan/TestCases/Linux/preinit_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/preinit_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/ptrace.cc (renamed from lib/asan/lit_tests/TestCases/Linux/ptrace.cc)0
-rw-r--r--test/asan/TestCases/Linux/rlimit_mmap_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/rlimit_mmap_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/shmctl.cc (renamed from lib/asan/lit_tests/TestCases/Linux/shmctl.cc)0
-rw-r--r--test/asan/TestCases/Linux/stress_dtls.c (renamed from lib/asan/lit_tests/TestCases/Linux/stress_dtls.c)0
-rw-r--r--test/asan/TestCases/Linux/swapcontext_test.cc (renamed from lib/asan/lit_tests/TestCases/Linux/swapcontext_test.cc)0
-rw-r--r--test/asan/TestCases/Linux/syscalls.cc (renamed from lib/asan/lit_tests/TestCases/Linux/syscalls.cc)0
-rw-r--r--test/asan/TestCases/Linux/tsd_dtor_leak.cc (renamed from lib/asan/lit_tests/TestCases/Linux/tsd_dtor_leak.cc)0
-rw-r--r--test/asan/TestCases/Linux/uar_signals.cc (renamed from lib/asan/lit_tests/TestCases/Linux/uar_signals.cc)0
-rw-r--r--test/asan/TestCases/Linux/unpoison_tls.cc (renamed from lib/asan/lit_tests/TestCases/Linux/unpoison_tls.cc)0
-rw-r--r--test/asan/TestCases/SharedLibs/darwin-dummy-shared-lib-so.cc (renamed from lib/asan/lit_tests/TestCases/SharedLibs/darwin-dummy-shared-lib-so.cc)0
-rw-r--r--test/asan/TestCases/SharedLibs/dlclose-test-so.cc (renamed from lib/asan/lit_tests/TestCases/SharedLibs/dlclose-test-so.cc)0
-rw-r--r--test/asan/TestCases/SharedLibs/init-order-dlopen-so.cc (renamed from lib/asan/lit_tests/TestCases/SharedLibs/init-order-dlopen-so.cc)0
-rw-r--r--test/asan/TestCases/SharedLibs/lit.local.cfg (renamed from lib/asan/lit_tests/TestCases/SharedLibs/lit.local.cfg)0
-rw-r--r--test/asan/TestCases/SharedLibs/shared-lib-test-so.cc (renamed from lib/asan/lit_tests/TestCases/SharedLibs/shared-lib-test-so.cc)0
-rw-r--r--test/asan/TestCases/SharedLibs/start-deactivated-so.cc (renamed from lib/asan/lit_tests/TestCases/SharedLibs/start-deactivated-so.cc)0
-rw-r--r--test/asan/TestCases/allocator_returns_null.cc (renamed from lib/asan/lit_tests/TestCases/allocator_returns_null.cc)0
-rw-r--r--test/asan/TestCases/allow_user_segv.cc (renamed from lib/asan/lit_tests/TestCases/allow_user_segv.cc)0
-rw-r--r--test/asan/TestCases/asan-symbolize-sanity-test.cc (renamed from lib/asan/lit_tests/TestCases/asan-symbolize-sanity-test.cc)0
-rw-r--r--test/asan/TestCases/assign_large_valloc_to_global.cc (renamed from lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc)0
-rw-r--r--test/asan/TestCases/atexit_stats.cc (renamed from lib/asan/lit_tests/TestCases/atexit_stats.cc)0
-rw-r--r--test/asan/TestCases/blacklist.cc (renamed from lib/asan/lit_tests/TestCases/blacklist.cc)0
-rw-r--r--test/asan/TestCases/contiguous_container.cc (renamed from lib/asan/lit_tests/TestCases/contiguous_container.cc)0
-rw-r--r--test/asan/TestCases/contiguous_container_crash.cc (renamed from lib/asan/lit_tests/TestCases/contiguous_container_crash.cc)0
-rw-r--r--test/asan/TestCases/current_allocated_bytes.cc (renamed from lib/asan/lit_tests/TestCases/current_allocated_bytes.cc)0
-rw-r--r--test/asan/TestCases/deep_call_stack.cc (renamed from lib/asan/lit_tests/TestCases/deep_call_stack.cc)0
-rw-r--r--test/asan/TestCases/deep_stack_uaf.cc (renamed from lib/asan/lit_tests/TestCases/deep_stack_uaf.cc)0
-rw-r--r--test/asan/TestCases/deep_tail_call.cc (renamed from lib/asan/lit_tests/TestCases/deep_tail_call.cc)0
-rw-r--r--test/asan/TestCases/deep_thread_stack.cc (renamed from lib/asan/lit_tests/TestCases/deep_thread_stack.cc)0
-rw-r--r--test/asan/TestCases/default_blacklist.cc (renamed from lib/asan/lit_tests/TestCases/default_blacklist.cc)0
-rw-r--r--test/asan/TestCases/default_options.cc (renamed from lib/asan/lit_tests/TestCases/default_options.cc)0
-rw-r--r--test/asan/TestCases/dlclose-test.cc (renamed from lib/asan/lit_tests/TestCases/dlclose-test.cc)0
-rw-r--r--test/asan/TestCases/double-free.cc (renamed from lib/asan/lit_tests/TestCases/double-free.cc)0
-rw-r--r--test/asan/TestCases/force_inline_opt0.cc (renamed from lib/asan/lit_tests/TestCases/force_inline_opt0.cc)0
-rw-r--r--test/asan/TestCases/free_hook_realloc.cc (renamed from lib/asan/lit_tests/TestCases/free_hook_realloc.cc)0
-rw-r--r--test/asan/TestCases/gc-test.cc (renamed from lib/asan/lit_tests/TestCases/gc-test.cc)0
-rw-r--r--test/asan/TestCases/global-demangle.cc (renamed from lib/asan/lit_tests/TestCases/global-demangle.cc)0
-rw-r--r--test/asan/TestCases/global-overflow.cc (renamed from lib/asan/lit_tests/TestCases/global-overflow.cc)0
-rw-r--r--test/asan/TestCases/heap-overflow.cc (renamed from lib/asan/lit_tests/TestCases/heap-overflow.cc)0
-rw-r--r--test/asan/TestCases/huge_negative_hea_oob.cc (renamed from lib/asan/lit_tests/TestCases/huge_negative_hea_oob.cc)0
-rw-r--r--test/asan/TestCases/init-order-atexit.cc (renamed from lib/asan/lit_tests/TestCases/init-order-atexit.cc)0
-rw-r--r--test/asan/TestCases/init-order-dlopen.cc (renamed from lib/asan/lit_tests/TestCases/init-order-dlopen.cc)0
-rw-r--r--test/asan/TestCases/init-order-pthread-create.cc (renamed from lib/asan/lit_tests/TestCases/init-order-pthread-create.cc)0
-rw-r--r--test/asan/TestCases/initialization-blacklist.cc (renamed from lib/asan/lit_tests/TestCases/initialization-blacklist.cc)0
-rw-r--r--test/asan/TestCases/initialization-bug.cc (renamed from lib/asan/lit_tests/TestCases/initialization-bug.cc)0
-rw-r--r--test/asan/TestCases/initialization-constexpr.cc (renamed from lib/asan/lit_tests/TestCases/initialization-constexpr.cc)0
-rw-r--r--test/asan/TestCases/initialization-nobug.cc (renamed from lib/asan/lit_tests/TestCases/initialization-nobug.cc)0
-rw-r--r--test/asan/TestCases/inline.cc (renamed from lib/asan/lit_tests/TestCases/inline.cc)0
-rw-r--r--test/asan/TestCases/interface_test.cc (renamed from lib/asan/lit_tests/TestCases/interface_test.cc)0
-rw-r--r--test/asan/TestCases/invalid-free.cc (renamed from lib/asan/lit_tests/TestCases/invalid-free.cc)0
-rw-r--r--test/asan/TestCases/ioctl.cc (renamed from lib/asan/lit_tests/TestCases/ioctl.cc)0
-rw-r--r--test/asan/TestCases/large_allocator_unpoisons_on_free.cc (renamed from lib/asan/lit_tests/TestCases/large_allocator_unpoisons_on_free.cc)0
-rw-r--r--test/asan/TestCases/large_func_test.cc (renamed from lib/asan/lit_tests/TestCases/large_func_test.cc)0
-rw-r--r--test/asan/TestCases/log-path_test.cc (renamed from lib/asan/lit_tests/TestCases/log-path_test.cc)0
-rw-r--r--test/asan/TestCases/log_path_fork_test.cc.disabled (renamed from lib/asan/lit_tests/TestCases/log_path_fork_test.cc.disabled)0
-rw-r--r--test/asan/TestCases/lsan_annotations.cc (renamed from lib/asan/lit_tests/TestCases/lsan_annotations.cc)0
-rw-r--r--test/asan/TestCases/malloc_context_size.cc (renamed from lib/asan/lit_tests/TestCases/malloc_context_size.cc)0
-rw-r--r--test/asan/TestCases/malloc_fill.cc (renamed from lib/asan/lit_tests/TestCases/malloc_fill.cc)0
-rw-r--r--test/asan/TestCases/malloc_hook.cc (renamed from lib/asan/lit_tests/TestCases/malloc_hook.cc)0
-rw-r--r--test/asan/TestCases/max_redzone.cc (renamed from lib/asan/lit_tests/TestCases/max_redzone.cc)0
-rw-r--r--test/asan/TestCases/memcmp_strict_test.cc (renamed from lib/asan/lit_tests/TestCases/memcmp_strict_test.cc)0
-rw-r--r--test/asan/TestCases/memcmp_test.cc (renamed from lib/asan/lit_tests/TestCases/memcmp_test.cc)0
-rw-r--r--test/asan/TestCases/no_asan_gen_globals.c (renamed from lib/asan/lit_tests/TestCases/no_asan_gen_globals.c)0
-rw-r--r--test/asan/TestCases/null_deref.cc (renamed from lib/asan/lit_tests/TestCases/null_deref.cc)0
-rw-r--r--test/asan/TestCases/on_error_callback.cc (renamed from lib/asan/lit_tests/TestCases/on_error_callback.cc)0
-rw-r--r--test/asan/TestCases/partial_right.cc (renamed from lib/asan/lit_tests/TestCases/partial_right.cc)0
-rw-r--r--test/asan/TestCases/poison_partial.cc (renamed from lib/asan/lit_tests/TestCases/poison_partial.cc)0
-rw-r--r--test/asan/TestCases/print-stack-trace.cc (renamed from lib/asan/lit_tests/TestCases/print-stack-trace.cc)0
-rw-r--r--test/asan/TestCases/print_summary.cc (renamed from lib/asan/lit_tests/TestCases/print_summary.cc)0
-rw-r--r--test/asan/TestCases/printf-1.c (renamed from lib/asan/lit_tests/TestCases/printf-1.c)0
-rw-r--r--test/asan/TestCases/printf-2.c (renamed from lib/asan/lit_tests/TestCases/printf-2.c)0
-rw-r--r--test/asan/TestCases/printf-3.c (renamed from lib/asan/lit_tests/TestCases/printf-3.c)0
-rw-r--r--test/asan/TestCases/printf-4.c (renamed from lib/asan/lit_tests/TestCases/printf-4.c)0
-rw-r--r--test/asan/TestCases/printf-5.c (renamed from lib/asan/lit_tests/TestCases/printf-5.c)0
-rw-r--r--test/asan/TestCases/readv.cc (renamed from lib/asan/lit_tests/TestCases/readv.cc)0
-rw-r--r--test/asan/TestCases/sanity_check_pure_c.c (renamed from lib/asan/lit_tests/TestCases/sanity_check_pure_c.c)0
-rw-r--r--test/asan/TestCases/shared-lib-test.cc (renamed from lib/asan/lit_tests/TestCases/shared-lib-test.cc)0
-rw-r--r--test/asan/TestCases/sleep_before_dying.c (renamed from lib/asan/lit_tests/TestCases/sleep_before_dying.c)0
-rw-r--r--test/asan/TestCases/stack-buffer-overflow-with-position.cc (renamed from lib/asan/lit_tests/TestCases/stack-buffer-overflow-with-position.cc)0
-rw-r--r--test/asan/TestCases/stack-frame-demangle.cc (renamed from lib/asan/lit_tests/TestCases/stack-frame-demangle.cc)0
-rw-r--r--test/asan/TestCases/stack-oob-frames.cc (renamed from lib/asan/lit_tests/TestCases/stack-oob-frames.cc)0
-rw-r--r--test/asan/TestCases/stack-overflow.cc (renamed from lib/asan/lit_tests/TestCases/stack-overflow.cc)0
-rw-r--r--test/asan/TestCases/stack-use-after-return.cc (renamed from lib/asan/lit_tests/TestCases/stack-use-after-return.cc)0
-rw-r--r--test/asan/TestCases/start-deactivated.cc (renamed from lib/asan/lit_tests/TestCases/start-deactivated.cc)0
-rw-r--r--test/asan/TestCases/strdup_oob_test.cc (renamed from lib/asan/lit_tests/TestCases/strdup_oob_test.cc)0
-rw-r--r--test/asan/TestCases/strerror_r_test.cc (renamed from lib/asan/lit_tests/TestCases/strerror_r_test.cc)0
-rw-r--r--test/asan/TestCases/strip_path_prefix.c (renamed from lib/asan/lit_tests/TestCases/strip_path_prefix.c)0
-rw-r--r--test/asan/TestCases/strncpy-overflow.cc (renamed from lib/asan/lit_tests/TestCases/strncpy-overflow.cc)0
-rw-r--r--test/asan/TestCases/throw_call_test.cc (renamed from lib/asan/lit_tests/TestCases/throw_call_test.cc)0
-rw-r--r--test/asan/TestCases/throw_catch.cc (renamed from lib/asan/lit_tests/TestCases/throw_catch.cc)0
-rw-r--r--test/asan/TestCases/throw_invoke_test.cc (renamed from lib/asan/lit_tests/TestCases/throw_invoke_test.cc)0
-rw-r--r--test/asan/TestCases/time_interceptor.cc (renamed from lib/asan/lit_tests/TestCases/time_interceptor.cc)0
-rw-r--r--test/asan/TestCases/uar_and_exceptions.cc (renamed from lib/asan/lit_tests/TestCases/uar_and_exceptions.cc)0
-rw-r--r--test/asan/TestCases/unaligned_loads_and_stores.cc (renamed from lib/asan/lit_tests/TestCases/unaligned_loads_and_stores.cc)0
-rw-r--r--test/asan/TestCases/use-after-free-right.cc (renamed from lib/asan/lit_tests/TestCases/use-after-free-right.cc)0
-rw-r--r--test/asan/TestCases/use-after-free.cc (renamed from lib/asan/lit_tests/TestCases/use-after-free.cc)0
-rw-r--r--test/asan/TestCases/use-after-poison.cc (renamed from lib/asan/lit_tests/TestCases/use-after-poison.cc)0
-rw-r--r--test/asan/TestCases/use-after-scope-dtor-order.cc (renamed from lib/asan/lit_tests/TestCases/use-after-scope-dtor-order.cc)0
-rw-r--r--test/asan/TestCases/use-after-scope-inlined.cc (renamed from lib/asan/lit_tests/TestCases/use-after-scope-inlined.cc)0
-rw-r--r--test/asan/TestCases/use-after-scope-nobug.cc (renamed from lib/asan/lit_tests/TestCases/use-after-scope-nobug.cc)0
-rw-r--r--test/asan/TestCases/use-after-scope-temp.cc (renamed from lib/asan/lit_tests/TestCases/use-after-scope-temp.cc)0
-rw-r--r--test/asan/TestCases/use-after-scope.cc (renamed from lib/asan/lit_tests/TestCases/use-after-scope.cc)0
-rw-r--r--test/asan/TestCases/wait.cc (renamed from lib/asan/lit_tests/TestCases/wait.cc)0
-rw-r--r--test/asan/TestCases/waitid.cc (renamed from lib/asan/lit_tests/TestCases/waitid.cc)0
-rw-r--r--test/asan/Unit/lit.site.cfg.in (renamed from lib/asan/lit_tests/Unit/lit.site.cfg.in)3
-rw-r--r--test/asan/android_commands/android_common.py (renamed from lib/asan/lit_tests/android_commands/android_common.py)0
-rwxr-xr-xtest/asan/android_commands/android_compile.py (renamed from lib/asan/lit_tests/android_commands/android_compile.py)0
-rwxr-xr-xtest/asan/android_commands/android_run.py (renamed from lib/asan/lit_tests/android_commands/android_run.py)0
-rw-r--r--test/asan/lit.cfg (renamed from lib/asan/lit_tests/lit.cfg)41
155 files changed, 80 insertions, 113 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3bbcf0af2..b13c93fbc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -231,6 +231,7 @@ endif()
# support only subset of these (e.g. TSan works on x86_64 only).
filter_available_targets(SANITIZER_COMMON_SUPPORTED_ARCH
x86_64 i386 powerpc64 arm)
+filter_available_targets(ASAN_SUPPORTED_ARCH x86_64 i386 powerpc64)
filter_available_targets(DFSAN_SUPPORTED_ARCH x86_64)
filter_available_targets(LSAN_SUPPORTED_ARCH x86_64)
filter_available_targets(MSAN_SUPPORTED_ARCH x86_64)
@@ -259,6 +260,6 @@ endif()
add_subdirectory(lib)
if(LLVM_INCLUDE_TESTS)
- add_subdirectory(test)
add_subdirectory(unittests)
endif()
+add_subdirectory(test)
diff --git a/lib/asan/CMakeLists.txt b/lib/asan/CMakeLists.txt
index 52eb8efe6..6b194079f 100644
--- a/lib/asan/CMakeLists.txt
+++ b/lib/asan/CMakeLists.txt
@@ -46,10 +46,6 @@ if(ANDROID)
ASAN_LOW_MEMORY=1)
endif()
-# Architectures supported by ASan.
-filter_available_targets(ASAN_SUPPORTED_ARCH
- x86_64 i386 powerpc64)
-
# Compile ASan sources into an object library.
if(APPLE)
foreach(os ${SANITIZER_COMMON_SUPPORTED_DARWIN_OS})
@@ -145,5 +141,3 @@ add_custom_target(asan_runtime_libraries
if(LLVM_INCLUDE_TESTS)
add_subdirectory(tests)
endif()
-
-add_subdirectory(lit_tests)
diff --git a/lib/asan/lit_tests/CMakeLists.txt b/lib/asan/lit_tests/CMakeLists.txt
deleted file mode 100644
index 223052a16..000000000
--- a/lib/asan/lit_tests/CMakeLists.txt
+++ /dev/null
@@ -1,65 +0,0 @@
-set(ASAN_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/..)
-set(ASAN_BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}/..)
-
-if(COMPILER_RT_CAN_EXECUTE_TESTS)
- set(ASAN_TESTSUITES)
-
- if(CAN_TARGET_arm_android)
- # This is only true if we are cross-compiling.
- # Build all tests with host compiler and use host tools.
- set(ASAN_TEST_TARGET_CC ${CMAKE_C_COMPILER})
- get_filename_component(ASAN_TEST_LLVM_TOOLS_DIR ${CMAKE_C_COMPILER} PATH)
- set(ASAN_TEST_CONFIG_SUFFIX "-arm-android")
- set(ASAN_TEST_BITS "32")
- get_target_flags_for_arch(arm_android ASAN_TEST_TARGET_CFLAGS)
- configure_lit_site_cfg(
- ${CMAKE_CURRENT_SOURCE_DIR}/GenericConfig/lit.site.cfg.in
- ${CMAKE_CURRENT_BINARY_DIR}/ARMAndroidConfig/lit.site.cfg
- )
- list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/ARMAndroidConfig)
- endif()
-
- if(CAN_TARGET_x86_64 OR CAN_TARGET_powerpc64)
- set(ASAN_TEST_CONFIG_SUFFIX "64")
- set(ASAN_TEST_BITS "64")
- set(ASAN_TEST_TARGET_CFLAGS ${TARGET_64_BIT_CFLAGS})
- configure_lit_site_cfg(
- ${CMAKE_CURRENT_SOURCE_DIR}/GenericConfig/lit.site.cfg.in
- ${CMAKE_CURRENT_BINARY_DIR}/64bitConfig/lit.site.cfg
- )
- list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/64bitConfig)
- endif()
-
- if(CAN_TARGET_i386)
- set(ASAN_TEST_CONFIG_SUFFIX "32")
- set(ASAN_TEST_BITS "32")
- set(ASAN_TEST_TARGET_CFLAGS ${TARGET_32_BIT_CFLAGS})
- configure_lit_site_cfg(
- ${CMAKE_CURRENT_SOURCE_DIR}/GenericConfig/lit.site.cfg.in
- ${CMAKE_CURRENT_BINARY_DIR}/32bitConfig/lit.site.cfg
- )
- list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/32bitConfig)
- endif()
-
- configure_lit_site_cfg(
- ${CMAKE_CURRENT_SOURCE_DIR}/Unit/lit.site.cfg.in
- ${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
- )
-
- # Run ASan tests only if we're sure we may produce working binaries.
- set(ASAN_TEST_DEPS
- ${SANITIZER_COMMON_LIT_TEST_DEPS}
- asan_runtime_libraries)
- set(ASAN_TEST_PARAMS
- asan_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg)
- # FIXME: support unit test in the android test runner
- if(LLVM_INCLUDE_TESTS AND NOT CAN_TARGET_arm_android)
- list(APPEND ASAN_TEST_DEPS AsanUnitTests)
- list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/Unit)
- endif()
- add_lit_testsuite(check-asan "Running the AddressSanitizer tests"
- ${ASAN_TESTSUITES}
- PARAMS ${ASAN_TEST_PARAMS}
- DEPENDS ${ASAN_TEST_DEPS})
- set_target_properties(check-asan PROPERTIES FOLDER "ASan tests")
-endif()
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 4b8401e62..590c2d38d 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -9,6 +9,9 @@ configure_lit_site_cfg(
# Run sanitizer tests only if we're sure that clang would produce
# working binaries.
if(COMPILER_RT_CAN_EXECUTE_TESTS)
+ if(ASAN_SUPPORTED_ARCH)
+ add_subdirectory(asan)
+ endif()
if(DFSAN_SUPPORTED_ARCH)
add_subdirectory(dfsan)
endif()
diff --git a/test/asan/CMakeLists.txt b/test/asan/CMakeLists.txt
new file mode 100644
index 000000000..c47d04876
--- /dev/null
+++ b/test/asan/CMakeLists.txt
@@ -0,0 +1,64 @@
+set(ASAN_LIT_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR})
+
+set(ASAN_TESTSUITES)
+
+if(CAN_TARGET_arm_android)
+ # This is only true if we are cross-compiling.
+ # Build all tests with host compiler and use host tools.
+ set(ASAN_TEST_TARGET_CC ${CMAKE_C_COMPILER})
+ get_filename_component(ASAN_TEST_LLVM_TOOLS_DIR ${CMAKE_C_COMPILER} PATH)
+ set(ASAN_TEST_CONFIG_SUFFIX "-arm-android")
+ set(ASAN_TEST_BITS "32")
+ get_target_flags_for_arch(arm_android ASAN_TEST_TARGET_CFLAGS)
+ configure_lit_site_cfg(
+ ${CMAKE_CURRENT_SOURCE_DIR}/GenericConfig/lit.site.cfg.in
+ ${CMAKE_CURRENT_BINARY_DIR}/ARMAndroidConfig/lit.site.cfg
+ )
+ list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/ARMAndroidConfig)
+endif()
+
+if(CAN_TARGET_x86_64 OR CAN_TARGET_powerpc64)
+ set(ASAN_TEST_CONFIG_SUFFIX "64")
+ set(ASAN_TEST_BITS "64")
+ set(ASAN_TEST_TARGET_CFLAGS ${TARGET_64_BIT_CFLAGS})
+ configure_lit_site_cfg(
+ ${CMAKE_CURRENT_SOURCE_DIR}/GenericConfig/lit.site.cfg.in
+ ${CMAKE_CURRENT_BINARY_DIR}/64bitConfig/lit.site.cfg
+ )
+ list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/64bitConfig)
+endif()
+
+if(CAN_TARGET_i386)
+ set(ASAN_TEST_CONFIG_SUFFIX "32")
+ set(ASAN_TEST_BITS "32")
+ set(ASAN_TEST_TARGET_CFLAGS ${TARGET_32_BIT_CFLAGS})
+ configure_lit_site_cfg(
+ ${CMAKE_CURRENT_SOURCE_DIR}/GenericConfig/lit.site.cfg.in
+ ${CMAKE_CURRENT_BINARY_DIR}/32bitConfig/lit.site.cfg
+ )
+ list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/32bitConfig)
+endif()
+
+if(LLVM_INCLUDE_TESTS)
+configure_lit_site_cfg(
+ ${CMAKE_CURRENT_SOURCE_DIR}/Unit/lit.site.cfg.in
+ ${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
+ )
+endif()
+
+# Run ASan tests only if we're sure we may produce working binaries.
+set(ASAN_TEST_DEPS
+ ${SANITIZER_COMMON_LIT_TEST_DEPS}
+ asan_runtime_libraries)
+set(ASAN_TEST_PARAMS
+ asan_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg)
+# FIXME: support unit test in the android test runner
+if(LLVM_INCLUDE_TESTS AND NOT CAN_TARGET_arm_android)
+ list(APPEND ASAN_TEST_DEPS AsanUnitTests)
+ list(APPEND ASAN_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/Unit)
+endif()
+add_lit_testsuite(check-asan "Running the AddressSanitizer tests"
+ ${ASAN_TESTSUITES}
+ PARAMS ${ASAN_TEST_PARAMS}
+ DEPENDS ${ASAN_TEST_DEPS})
+set_target_properties(check-asan PROPERTIES FOLDER "ASan tests")
diff --git a/lib/asan/lit_tests/GenericConfig/lit.site.cfg.in b/test/asan/GenericConfig/lit.site.cfg.in
index 7d552f3fc..48ea81252 100644
--- a/lib/asan/lit_tests/GenericConfig/lit.site.cfg.in
+++ b/test/asan/GenericConfig/lit.site.cfg.in
@@ -3,7 +3,7 @@
# Tool-specific config options.
config.name_suffix = "@ASAN_TEST_CONFIG_SUFFIX@"
-config.asan_source_dir = "@ASAN_SOURCE_DIR@"
+config.asan_lit_source_dir = "@ASAN_LIT_SOURCE_DIR@"
config.target_cflags = "@ASAN_TEST_TARGET_CFLAGS@"
config.clang = "@ASAN_TEST_TARGET_CC@"
config.llvm_tools_dir = "@ASAN_TEST_LLVM_TOOLS_DIR@"
@@ -14,4 +14,4 @@ config.android = "@CAN_TARGET_arm_android@"
lit_config.load_config(config, "@COMPILER_RT_BINARY_DIR@/test/lit.common.configured")
# Load tool-specific config that would do the real work.
-lit_config.load_config(config, "@ASAN_SOURCE_DIR@/lit_tests/lit.cfg")
+lit_config.load_config(config, "@ASAN_LIT_SOURCE_DIR@/lit.cfg")
diff --git a/lib/asan/lit_tests/TestCases/Darwin/asan_gen_prefixes.cc b/test/asan/TestCases/Darwin/asan_gen_prefixes.cc
index 13363ac47..13363ac47 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/asan_gen_prefixes.cc
+++ b/test/asan/TestCases/Darwin/asan_gen_prefixes.cc
diff --git a/lib/asan/lit_tests/TestCases/Darwin/interface_symbols_darwin.c b/test/asan/TestCases/Darwin/interface_symbols_darwin.c
index 962422a96..03042d62a 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/interface_symbols_darwin.c
+++ b/test/asan/TestCases/Darwin/interface_symbols_darwin.c
@@ -15,7 +15,7 @@
// RUN: | grep -v "__asan_default_options" \
// RUN: | grep -v "__asan_on_error" > %t.symbols
-// RUN: cat %p/../../../asan_interface_internal.h \
+// RUN: cat %p/../../../../lib/asan/asan_interface_internal.h \
// RUN: | sed "s/\/\/.*//" | sed "s/typedef.*//" \
// RUN: | grep -v "OPTIONAL" \
// RUN: | grep "__asan_.*(" | sed "s/.* __asan_/__asan_/;s/(.*//" \
diff --git a/lib/asan/lit_tests/TestCases/Darwin/lit.local.cfg b/test/asan/TestCases/Darwin/lit.local.cfg
index a85dfcd24..a85dfcd24 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/lit.local.cfg
+++ b/test/asan/TestCases/Darwin/lit.local.cfg
diff --git a/lib/asan/lit_tests/TestCases/Darwin/malloc_set_zone_name-mprotect.cc b/test/asan/TestCases/Darwin/malloc_set_zone_name-mprotect.cc
index 807a8283e..807a8283e 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/malloc_set_zone_name-mprotect.cc
+++ b/test/asan/TestCases/Darwin/malloc_set_zone_name-mprotect.cc
diff --git a/lib/asan/lit_tests/TestCases/Darwin/malloc_zone-protected.cc b/test/asan/TestCases/Darwin/malloc_zone-protected.cc
index d5f6c7c12..d5f6c7c12 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/malloc_zone-protected.cc
+++ b/test/asan/TestCases/Darwin/malloc_zone-protected.cc
diff --git a/lib/asan/lit_tests/TestCases/Darwin/reexec-insert-libraries-env.cc b/test/asan/TestCases/Darwin/reexec-insert-libraries-env.cc
index 208fe43ac..208fe43ac 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/reexec-insert-libraries-env.cc
+++ b/test/asan/TestCases/Darwin/reexec-insert-libraries-env.cc
diff --git a/lib/asan/lit_tests/TestCases/Darwin/unset-insert-libraries-on-exec.cc b/test/asan/TestCases/Darwin/unset-insert-libraries-on-exec.cc
index fa0dd4f9d..fa0dd4f9d 100644
--- a/lib/asan/lit_tests/TestCases/Darwin/unset-insert-libraries-on-exec.cc
+++ b/test/asan/TestCases/Darwin/unset-insert-libraries-on-exec.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/blacklist-extra.cc b/test/asan/TestCases/Helpers/blacklist-extra.cc
index 627115cdd..627115cdd 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/blacklist-extra.cc
+++ b/test/asan/TestCases/Helpers/blacklist-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/echo-env.cc b/test/asan/TestCases/Helpers/echo-env.cc
index 65e91c155..65e91c155 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/echo-env.cc
+++ b/test/asan/TestCases/Helpers/echo-env.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/init-order-atexit-extra.cc b/test/asan/TestCases/Helpers/init-order-atexit-extra.cc
index e4189d19d..e4189d19d 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/init-order-atexit-extra.cc
+++ b/test/asan/TestCases/Helpers/init-order-atexit-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/init-order-pthread-create-extra.cc b/test/asan/TestCases/Helpers/init-order-pthread-create-extra.cc
index d4606f0af..d4606f0af 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/init-order-pthread-create-extra.cc
+++ b/test/asan/TestCases/Helpers/init-order-pthread-create-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist-extra.cc b/test/asan/TestCases/Helpers/initialization-blacklist-extra.cc
index 09aed2112..09aed2112 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist-extra.cc
+++ b/test/asan/TestCases/Helpers/initialization-blacklist-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist-extra2.cc b/test/asan/TestCases/Helpers/initialization-blacklist-extra2.cc
index 69455a0a6..69455a0a6 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist-extra2.cc
+++ b/test/asan/TestCases/Helpers/initialization-blacklist-extra2.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist.txt b/test/asan/TestCases/Helpers/initialization-blacklist.txt
index 832946356..832946356 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-blacklist.txt
+++ b/test/asan/TestCases/Helpers/initialization-blacklist.txt
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-bug-extra.cc b/test/asan/TestCases/Helpers/initialization-bug-extra.cc
index 3c4cb411d..3c4cb411d 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-bug-extra.cc
+++ b/test/asan/TestCases/Helpers/initialization-bug-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-bug-extra2.cc b/test/asan/TestCases/Helpers/initialization-bug-extra2.cc
index a3d8f190e..a3d8f190e 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-bug-extra2.cc
+++ b/test/asan/TestCases/Helpers/initialization-bug-extra2.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-constexpr-extra.cc b/test/asan/TestCases/Helpers/initialization-constexpr-extra.cc
index b32466a98..b32466a98 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-constexpr-extra.cc
+++ b/test/asan/TestCases/Helpers/initialization-constexpr-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/initialization-nobug-extra.cc b/test/asan/TestCases/Helpers/initialization-nobug-extra.cc
index 886165aff..886165aff 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/initialization-nobug-extra.cc
+++ b/test/asan/TestCases/Helpers/initialization-nobug-extra.cc
diff --git a/lib/asan/lit_tests/TestCases/Helpers/lit.local.cfg b/test/asan/TestCases/Helpers/lit.local.cfg
index 2fc4d9945..2fc4d9945 100644
--- a/lib/asan/lit_tests/TestCases/Helpers/lit.local.cfg
+++ b/test/asan/TestCases/Helpers/lit.local.cfg
diff --git a/lib/asan/lit_tests/TestCases/Linux/asan_prelink_test.cc b/test/asan/TestCases/Linux/asan_prelink_test.cc
index 0f158c1bb..0f158c1bb 100644
--- a/lib/asan/lit_tests/TestCases/Linux/asan_prelink_test.cc
+++ b/test/asan/TestCases/Linux/asan_prelink_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/clone_test.cc b/test/asan/TestCases/Linux/clone_test.cc
index 432190a18..432190a18 100644
--- a/lib/asan/lit_tests/TestCases/Linux/clone_test.cc
+++ b/test/asan/TestCases/Linux/clone_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/coverage.cc b/test/asan/TestCases/Linux/coverage.cc
index 449e1c446..449e1c446 100644
--- a/lib/asan/lit_tests/TestCases/Linux/coverage.cc
+++ b/test/asan/TestCases/Linux/coverage.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/function-sections-are-bad.cc b/test/asan/TestCases/Linux/function-sections-are-bad.cc
index cccd6ca1c..cccd6ca1c 100644
--- a/lib/asan/lit_tests/TestCases/Linux/function-sections-are-bad.cc
+++ b/test/asan/TestCases/Linux/function-sections-are-bad.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/glob.cc b/test/asan/TestCases/Linux/glob.cc
index 123768b09..123768b09 100644
--- a/lib/asan/lit_tests/TestCases/Linux/glob.cc
+++ b/test/asan/TestCases/Linux/glob.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/glob_test_root/aa b/test/asan/TestCases/Linux/glob_test_root/aa
index e69de29bb..e69de29bb 100644
--- a/lib/asan/lit_tests/TestCases/Linux/glob_test_root/aa
+++ b/test/asan/TestCases/Linux/glob_test_root/aa
diff --git a/lib/asan/lit_tests/TestCases/Linux/glob_test_root/ab b/test/asan/TestCases/Linux/glob_test_root/ab
index e69de29bb..e69de29bb 100644
--- a/lib/asan/lit_tests/TestCases/Linux/glob_test_root/ab
+++ b/test/asan/TestCases/Linux/glob_test_root/ab
diff --git a/lib/asan/lit_tests/TestCases/Linux/glob_test_root/ba b/test/asan/TestCases/Linux/glob_test_root/ba
index e69de29bb..e69de29bb 100644
--- a/lib/asan/lit_tests/TestCases/Linux/glob_test_root/ba
+++ b/test/asan/TestCases/Linux/glob_test_root/ba
diff --git a/lib/asan/lit_tests/TestCases/Linux/globals-gc-sections.cc b/test/asan/TestCases/Linux/globals-gc-sections.cc
index 72a9e9498..72a9e9498 100644
--- a/lib/asan/lit_tests/TestCases/Linux/globals-gc-sections.cc
+++ b/test/asan/TestCases/Linux/globals-gc-sections.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/heap-overflow-large.cc b/test/asan/TestCases/Linux/heap-overflow-large.cc
index 67e9c3718..67e9c3718 100644
--- a/lib/asan/lit_tests/TestCases/Linux/heap-overflow-large.cc
+++ b/test/asan/TestCases/Linux/heap-overflow-large.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc b/test/asan/TestCases/Linux/heavy_uar_test.cc
index 0e2bf2fee..0e2bf2fee 100644
--- a/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc
+++ b/test/asan/TestCases/Linux/heavy_uar_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/initialization-bug-any-order.cc b/test/asan/TestCases/Linux/initialization-bug-any-order.cc
index 042a07e42..042a07e42 100644
--- a/lib/asan/lit_tests/TestCases/Linux/initialization-bug-any-order.cc
+++ b/test/asan/TestCases/Linux/initialization-bug-any-order.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/interception_failure_test.cc b/test/asan/TestCases/Linux/interception_failure_test.cc
index 9d161aa2d..9d161aa2d 100644
--- a/lib/asan/lit_tests/TestCases/Linux/interception_failure_test.cc
+++ b/test/asan/TestCases/Linux/interception_failure_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/interception_malloc_test.cc b/test/asan/TestCases/Linux/interception_malloc_test.cc
index cdd7239ab..cdd7239ab 100644
--- a/lib/asan/lit_tests/TestCases/Linux/interception_malloc_test.cc
+++ b/test/asan/TestCases/Linux/interception_malloc_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/interception_readdir_r_test.cc b/test/asan/TestCases/Linux/interception_readdir_r_test.cc
index 198e1f388..198e1f388 100644
--- a/lib/asan/lit_tests/TestCases/Linux/interception_readdir_r_test.cc
+++ b/test/asan/TestCases/Linux/interception_readdir_r_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/interception_test.cc b/test/asan/TestCases/Linux/interception_test.cc
index 2b3316d7d..2b3316d7d 100644
--- a/lib/asan/lit_tests/TestCases/Linux/interception_test.cc
+++ b/test/asan/TestCases/Linux/interception_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/interface_symbols_linux.c b/test/asan/TestCases/Linux/interface_symbols_linux.c
index ea33084ad..f67a12476 100644
--- a/lib/asan/lit_tests/TestCases/Linux/interface_symbols_linux.c
+++ b/test/asan/TestCases/Linux/interface_symbols_linux.c
@@ -8,7 +8,7 @@
// RUN: | grep -v "__asan_default_options" \
// RUN: | grep -v "__asan_stack_" \
// RUN: | grep -v "__asan_on_error" > %t.symbols
-// RUN: cat %p/../../../asan_interface_internal.h \
+// RUN: cat %p/../../../../lib/asan/asan_interface_internal.h \
// RUN: | sed "s/\/\/.*//" | sed "s/typedef.*//" \
// RUN: | grep -v "OPTIONAL" \
// RUN: | grep "__asan_.*(" | sed "s/.* __asan_/__asan_/;s/(.*//" \
diff --git a/lib/asan/lit_tests/TestCases/Linux/lit.local.cfg b/test/asan/TestCases/Linux/lit.local.cfg
index 57271b807..57271b807 100644
--- a/lib/asan/lit_tests/TestCases/Linux/lit.local.cfg
+++ b/test/asan/TestCases/Linux/lit.local.cfg
diff --git a/lib/asan/lit_tests/TestCases/Linux/malloc-in-qsort.cc b/test/asan/TestCases/Linux/malloc-in-qsort.cc
index 3251b35e1..3251b35e1 100644
--- a/lib/asan/lit_tests/TestCases/Linux/malloc-in-qsort.cc
+++ b/test/asan/TestCases/Linux/malloc-in-qsort.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/malloc_delete_mismatch.cc b/test/asan/TestCases/Linux/malloc_delete_mismatch.cc
index 7010eb2de..7010eb2de 100644
--- a/lib/asan/lit_tests/TestCases/Linux/malloc_delete_mismatch.cc
+++ b/test/asan/TestCases/Linux/malloc_delete_mismatch.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/overflow-in-qsort.cc b/test/asan/TestCases/Linux/overflow-in-qsort.cc
index 139977261..139977261 100644
--- a/lib/asan/lit_tests/TestCases/Linux/overflow-in-qsort.cc
+++ b/test/asan/TestCases/Linux/overflow-in-qsort.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/preinit_test.cc b/test/asan/TestCases/Linux/preinit_test.cc
index 28e509472..28e509472 100644
--- a/lib/asan/lit_tests/TestCases/Linux/preinit_test.cc
+++ b/test/asan/TestCases/Linux/preinit_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/ptrace.cc b/test/asan/TestCases/Linux/ptrace.cc
index 8831b81ef..8831b81ef 100644
--- a/lib/asan/lit_tests/TestCases/Linux/ptrace.cc
+++ b/test/asan/TestCases/Linux/ptrace.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/rlimit_mmap_test.cc b/test/asan/TestCases/Linux/rlimit_mmap_test.cc
index 0d1d4baa7..0d1d4baa7 100644
--- a/lib/asan/lit_tests/TestCases/Linux/rlimit_mmap_test.cc
+++ b/test/asan/TestCases/Linux/rlimit_mmap_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/shmctl.cc b/test/asan/TestCases/Linux/shmctl.cc
index c2e650a40..c2e650a40 100644
--- a/lib/asan/lit_tests/TestCases/Linux/shmctl.cc
+++ b/test/asan/TestCases/Linux/shmctl.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/stress_dtls.c b/test/asan/TestCases/Linux/stress_dtls.c
index 4e22f8ae9..4e22f8ae9 100644
--- a/lib/asan/lit_tests/TestCases/Linux/stress_dtls.c
+++ b/test/asan/TestCases/Linux/stress_dtls.c
diff --git a/lib/asan/lit_tests/TestCases/Linux/swapcontext_test.cc b/test/asan/TestCases/Linux/swapcontext_test.cc
index 6cbb69a35..6cbb69a35 100644
--- a/lib/asan/lit_tests/TestCases/Linux/swapcontext_test.cc
+++ b/test/asan/TestCases/Linux/swapcontext_test.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/syscalls.cc b/test/asan/TestCases/Linux/syscalls.cc
index 4bcbe4461..4bcbe4461 100644
--- a/lib/asan/lit_tests/TestCases/Linux/syscalls.cc
+++ b/test/asan/TestCases/Linux/syscalls.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/tsd_dtor_leak.cc b/test/asan/TestCases/Linux/tsd_dtor_leak.cc
index a1d89ee43..a1d89ee43 100644
--- a/lib/asan/lit_tests/TestCases/Linux/tsd_dtor_leak.cc
+++ b/test/asan/TestCases/Linux/tsd_dtor_leak.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc b/test/asan/TestCases/Linux/uar_signals.cc
index 9663859df..9663859df 100644
--- a/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc
+++ b/test/asan/TestCases/Linux/uar_signals.cc
diff --git a/lib/asan/lit_tests/TestCases/Linux/unpoison_tls.cc b/test/asan/TestCases/Linux/unpoison_tls.cc
index d67c4f954..d67c4f954 100644
--- a/lib/asan/lit_tests/TestCases/Linux/unpoison_tls.cc
+++ b/test/asan/TestCases/Linux/unpoison_tls.cc
diff --git a/lib/asan/lit_tests/TestCases/SharedLibs/darwin-dummy-shared-lib-so.cc b/test/asan/TestCases/SharedLibs/darwin-dummy-shared-lib-so.cc
index 5d9399914..5d9399914 100644
--- a/lib/asan/lit_tests/TestCases/SharedLibs/darwin-dummy-shared-lib-so.cc
+++ b/test/asan/TestCases/SharedLibs/darwin-dummy-shared-lib-so.cc
diff --git a/lib/asan/lit_tests/TestCases/SharedLibs/dlclose-test-so.cc b/test/asan/TestCases/SharedLibs/dlclose-test-so.cc
index 73e005073..73e005073 100644
--- a/lib/asan/lit_tests/TestCases/SharedLibs/dlclose-test-so.cc
+++ b/test/asan/TestCases/SharedLibs/dlclose-test-so.cc
diff --git a/lib/asan/lit_tests/TestCases/SharedLibs/init-order-dlopen-so.cc b/test/asan/TestCases/SharedLibs/init-order-dlopen-so.cc
index dc097a520..dc097a520 100644
--- a/lib/asan/lit_tests/TestCases/SharedLibs/init-order-dlopen-so.cc
+++ b/test/asan/TestCases/SharedLibs/init-order-dlopen-so.cc
diff --git a/lib/asan/lit_tests/TestCases/SharedLibs/lit.local.cfg b/test/asan/TestCases/SharedLibs/lit.local.cfg
index b3677c17a..b3677c17a 100644
--- a/lib/asan/lit_tests/TestCases/SharedLibs/lit.local.cfg
+++ b/test/asan/TestCases/SharedLibs/lit.local.cfg
diff --git a/lib/asan/lit_tests/TestCases/SharedLibs/shared-lib-test-so.cc b/test/asan/TestCases/SharedLibs/shared-lib-test-so.cc
index 6ef565ce4..6ef565ce4 100644
--- a/lib/asan/lit_tests/TestCases/SharedLibs/shared-lib-test-so.cc
+++ b/test/asan/TestCases/SharedLibs/shared-lib-test-so.cc
diff --git a/lib/asan/lit_tests/TestCases/SharedLibs/start-deactivated-so.cc b/test/asan/TestCases/SharedLibs/start-deactivated-so.cc
index 9611fa5ba..9611fa5ba 100644
--- a/lib/asan/lit_tests/TestCases/SharedLibs/start-deactivated-so.cc
+++ b/test/asan/TestCases/SharedLibs/start-deactivated-so.cc
diff --git a/lib/asan/lit_tests/TestCases/allocator_returns_null.cc b/test/asan/TestCases/allocator_returns_null.cc
index 595c9e252..595c9e252 100644
--- a/lib/asan/lit_tests/TestCases/allocator_returns_null.cc
+++ b/test/asan/TestCases/allocator_returns_null.cc
diff --git a/lib/asan/lit_tests/TestCases/allow_user_segv.cc b/test/asan/TestCases/allow_user_segv.cc
index 55cf6044e..55cf6044e 100644
--- a/lib/asan/lit_tests/TestCases/allow_user_segv.cc
+++ b/test/asan/TestCases/allow_user_segv.cc
diff --git a/lib/asan/lit_tests/TestCases/asan-symbolize-sanity-test.cc b/test/asan/TestCases/asan-symbolize-sanity-test.cc
index 0efe245bb..0efe245bb 100644
--- a/lib/asan/lit_tests/TestCases/asan-symbolize-sanity-test.cc
+++ b/test/asan/TestCases/asan-symbolize-sanity-test.cc
diff --git a/lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc b/test/asan/TestCases/assign_large_valloc_to_global.cc
index b0a501576..b0a501576 100644
--- a/lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc
+++ b/test/asan/TestCases/assign_large_valloc_to_global.cc
diff --git a/lib/asan/lit_tests/TestCases/atexit_stats.cc b/test/asan/TestCases/atexit_stats.cc
index e3b1269d2..e3b1269d2 100644
--- a/lib/asan/lit_tests/TestCases/atexit_stats.cc
+++ b/test/asan/TestCases/atexit_stats.cc
diff --git a/lib/asan/lit_tests/TestCases/blacklist.cc b/test/asan/TestCases/blacklist.cc
index 46625ee7b..46625ee7b 100644
--- a/lib/asan/lit_tests/TestCases/blacklist.cc
+++ b/test/asan/TestCases/blacklist.cc
diff --git a/lib/asan/lit_tests/TestCases/contiguous_container.cc b/test/asan/TestCases/contiguous_container.cc
index ebcd7c9a6..ebcd7c9a6 100644
--- a/lib/asan/lit_tests/TestCases/contiguous_container.cc
+++ b/test/asan/TestCases/contiguous_container.cc
diff --git a/lib/asan/lit_tests/TestCases/contiguous_container_crash.cc b/test/asan/TestCases/contiguous_container_crash.cc
index 6be9ad5f6..6be9ad5f6 100644
--- a/lib/asan/lit_tests/TestCases/contiguous_container_crash.cc
+++ b/test/asan/TestCases/contiguous_container_crash.cc
diff --git a/lib/asan/lit_tests/TestCases/current_allocated_bytes.cc b/test/asan/TestCases/current_allocated_bytes.cc
index 669cf150b..669cf150b 100644
--- a/lib/asan/lit_tests/TestCases/current_allocated_bytes.cc
+++ b/test/asan/TestCases/current_allocated_bytes.cc
diff --git a/lib/asan/lit_tests/TestCases/deep_call_stack.cc b/test/asan/TestCases/deep_call_stack.cc
index e24704b90..e24704b90 100644
--- a/lib/asan/lit_tests/TestCases/deep_call_stack.cc
+++ b/test/asan/TestCases/deep_call_stack.cc
diff --git a/lib/asan/lit_tests/TestCases/deep_stack_uaf.cc b/test/asan/TestCases/deep_stack_uaf.cc
index 920411c4a..920411c4a 100644
--- a/lib/asan/lit_tests/TestCases/deep_stack_uaf.cc
+++ b/test/asan/TestCases/deep_stack_uaf.cc
diff --git a/lib/asan/lit_tests/TestCases/deep_tail_call.cc b/test/asan/TestCases/deep_tail_call.cc
index 2e7aa8e02..2e7aa8e02 100644
--- a/lib/asan/lit_tests/TestCases/deep_tail_call.cc
+++ b/test/asan/TestCases/deep_tail_call.cc
diff --git a/lib/asan/lit_tests/TestCases/deep_thread_stack.cc b/test/asan/TestCases/deep_thread_stack.cc
index 92e0d66c8..92e0d66c8 100644
--- a/lib/asan/lit_tests/TestCases/deep_thread_stack.cc
+++ b/test/asan/TestCases/deep_thread_stack.cc
diff --git a/lib/asan/lit_tests/TestCases/default_blacklist.cc b/test/asan/TestCases/default_blacklist.cc
index 25a1ae175..25a1ae175 100644
--- a/lib/asan/lit_tests/TestCases/default_blacklist.cc
+++ b/test/asan/TestCases/default_blacklist.cc
diff --git a/lib/asan/lit_tests/TestCases/default_options.cc b/test/asan/TestCases/default_options.cc
index 84b80557b..84b80557b 100644
--- a/lib/asan/lit_tests/TestCases/default_options.cc
+++ b/test/asan/TestCases/default_options.cc
diff --git a/lib/asan/lit_tests/TestCases/dlclose-test.cc b/test/asan/TestCases/dlclose-test.cc
index 03ed16016..03ed16016 100644
--- a/lib/asan/lit_tests/TestCases/dlclose-test.cc
+++ b/test/asan/TestCases/dlclose-test.cc
diff --git a/lib/asan/lit_tests/TestCases/double-free.cc b/test/asan/TestCases/double-free.cc
index 6bfd4fa2c..6bfd4fa2c 100644
--- a/lib/asan/lit_tests/TestCases/double-free.cc
+++ b/test/asan/TestCases/double-free.cc
diff --git a/lib/asan/lit_tests/TestCases/force_inline_opt0.cc b/test/asan/TestCases/force_inline_opt0.cc
index 775a66dfe..775a66dfe 100644
--- a/lib/asan/lit_tests/TestCases/force_inline_opt0.cc
+++ b/test/asan/TestCases/force_inline_opt0.cc
diff --git a/lib/asan/lit_tests/TestCases/free_hook_realloc.cc b/test/asan/TestCases/free_hook_realloc.cc
index 7a71964b0..7a71964b0 100644
--- a/lib/asan/lit_tests/TestCases/free_hook_realloc.cc
+++ b/test/asan/TestCases/free_hook_realloc.cc
diff --git a/lib/asan/lit_tests/TestCases/gc-test.cc b/test/asan/TestCases/gc-test.cc
index 984146481..984146481 100644
--- a/lib/asan/lit_tests/TestCases/gc-test.cc
+++ b/test/asan/TestCases/gc-test.cc
diff --git a/lib/asan/lit_tests/TestCases/global-demangle.cc b/test/asan/TestCases/global-demangle.cc
index d050b70f0..d050b70f0 100644
--- a/lib/asan/lit_tests/TestCases/global-demangle.cc
+++ b/test/asan/TestCases/global-demangle.cc
diff --git a/lib/asan/lit_tests/TestCases/global-overflow.cc b/test/asan/TestCases/global-overflow.cc
index 0f080f55f..0f080f55f 100644
--- a/lib/asan/lit_tests/TestCases/global-overflow.cc
+++ b/test/asan/TestCases/global-overflow.cc
diff --git a/lib/asan/lit_tests/TestCases/heap-overflow.cc b/test/asan/TestCases/heap-overflow.cc
index 2c943a360..2c943a360 100644
--- a/lib/asan/lit_tests/TestCases/heap-overflow.cc
+++ b/test/asan/TestCases/heap-overflow.cc
diff --git a/lib/asan/lit_tests/TestCases/huge_negative_hea_oob.cc b/test/asan/TestCases/huge_negative_hea_oob.cc
index 58a44c5fb..58a44c5fb 100644
--- a/lib/asan/lit_tests/TestCases/huge_negative_hea_oob.cc
+++ b/test/asan/TestCases/huge_negative_hea_oob.cc
diff --git a/lib/asan/lit_tests/TestCases/init-order-atexit.cc b/test/asan/TestCases/init-order-atexit.cc
index e38cdd273..e38cdd273 100644
--- a/lib/asan/lit_tests/TestCases/init-order-atexit.cc
+++ b/test/asan/TestCases/init-order-atexit.cc
diff --git a/lib/asan/lit_tests/TestCases/init-order-dlopen.cc b/test/asan/TestCases/init-order-dlopen.cc
index d30d11999..d30d11999 100644
--- a/lib/asan/lit_tests/TestCases/init-order-dlopen.cc
+++ b/test/asan/TestCases/init-order-dlopen.cc
diff --git a/lib/asan/lit_tests/TestCases/init-order-pthread-create.cc b/test/asan/TestCases/init-order-pthread-create.cc
index 52031216d..52031216d 100644
--- a/lib/asan/lit_tests/TestCases/init-order-pthread-create.cc
+++ b/test/asan/TestCases/init-order-pthread-create.cc
diff --git a/lib/asan/lit_tests/TestCases/initialization-blacklist.cc b/test/asan/TestCases/initialization-blacklist.cc
index f40fcc082..f40fcc082 100644
--- a/lib/asan/lit_tests/TestCases/initialization-blacklist.cc
+++ b/test/asan/TestCases/initialization-blacklist.cc
diff --git a/lib/asan/lit_tests/TestCases/initialization-bug.cc b/test/asan/TestCases/initialization-bug.cc
index fb289b1c7..fb289b1c7 100644
--- a/lib/asan/lit_tests/TestCases/initialization-bug.cc
+++ b/test/asan/TestCases/initialization-bug.cc
diff --git a/lib/asan/lit_tests/TestCases/initialization-constexpr.cc b/test/asan/TestCases/initialization-constexpr.cc
index 65c95edd5..65c95edd5 100644
--- a/lib/asan/lit_tests/TestCases/initialization-constexpr.cc
+++ b/test/asan/TestCases/initialization-constexpr.cc
diff --git a/lib/asan/lit_tests/TestCases/initialization-nobug.cc b/test/asan/TestCases/initialization-nobug.cc
index ed37d137f..ed37d137f 100644
--- a/lib/asan/lit_tests/TestCases/initialization-nobug.cc
+++ b/test/asan/TestCases/initialization-nobug.cc
diff --git a/lib/asan/lit_tests/TestCases/inline.cc b/test/asan/TestCases/inline.cc
index 792aff59f..792aff59f 100644
--- a/lib/asan/lit_tests/TestCases/inline.cc
+++ b/test/asan/TestCases/inline.cc
diff --git a/lib/asan/lit_tests/TestCases/interface_test.cc b/test/asan/TestCases/interface_test.cc
index 297b5526e..297b5526e 100644
--- a/lib/asan/lit_tests/TestCases/interface_test.cc
+++ b/test/asan/TestCases/interface_test.cc
diff --git a/lib/asan/lit_tests/TestCases/invalid-free.cc b/test/asan/TestCases/invalid-free.cc
index f940b5012..f940b5012 100644
--- a/lib/asan/lit_tests/TestCases/invalid-free.cc
+++ b/test/asan/TestCases/invalid-free.cc
diff --git a/lib/asan/lit_tests/TestCases/ioctl.cc b/test/asan/TestCases/ioctl.cc
index 08ca688d3..08ca688d3 100644
--- a/lib/asan/lit_tests/TestCases/ioctl.cc
+++ b/test/asan/TestCases/ioctl.cc
diff --git a/lib/asan/lit_tests/TestCases/large_allocator_unpoisons_on_free.cc b/test/asan/TestCases/large_allocator_unpoisons_on_free.cc
index d1499d206..d1499d206 100644
--- a/lib/asan/lit_tests/TestCases/large_allocator_unpoisons_on_free.cc
+++ b/test/asan/TestCases/large_allocator_unpoisons_on_free.cc
diff --git a/lib/asan/lit_tests/TestCases/large_func_test.cc b/test/asan/TestCases/large_func_test.cc
index 0534bcd31..0534bcd31 100644
--- a/lib/asan/lit_tests/TestCases/large_func_test.cc
+++ b/test/asan/TestCases/large_func_test.cc
diff --git a/lib/asan/lit_tests/TestCases/log-path_test.cc b/test/asan/TestCases/log-path_test.cc
index 1072670fb..1072670fb 100644
--- a/lib/asan/lit_tests/TestCases/log-path_test.cc
+++ b/test/asan/TestCases/log-path_test.cc
diff --git a/lib/asan/lit_tests/TestCases/log_path_fork_test.cc.disabled b/test/asan/TestCases/log_path_fork_test.cc.disabled
index c6c1b49e9..c6c1b49e9 100644
--- a/lib/asan/lit_tests/TestCases/log_path_fork_test.cc.disabled
+++ b/test/asan/TestCases/log_path_fork_test.cc.disabled
diff --git a/lib/asan/lit_tests/TestCases/lsan_annotations.cc b/test/asan/TestCases/lsan_annotations.cc
index c55ab8692..c55ab8692 100644
--- a/lib/asan/lit_tests/TestCases/lsan_annotations.cc
+++ b/test/asan/TestCases/lsan_annotations.cc
diff --git a/lib/asan/lit_tests/TestCases/malloc_context_size.cc b/test/asan/TestCases/malloc_context_size.cc
index 266ce66f5..266ce66f5 100644
--- a/lib/asan/lit_tests/TestCases/malloc_context_size.cc
+++ b/test/asan/TestCases/malloc_context_size.cc
diff --git a/lib/asan/lit_tests/TestCases/malloc_fill.cc b/test/asan/TestCases/malloc_fill.cc
index 57f50d143..57f50d143 100644
--- a/lib/asan/lit_tests/TestCases/malloc_fill.cc
+++ b/test/asan/TestCases/malloc_fill.cc
diff --git a/lib/asan/lit_tests/TestCases/malloc_hook.cc b/test/asan/TestCases/malloc_hook.cc
index 83be1020e..83be1020e 100644
--- a/lib/asan/lit_tests/TestCases/malloc_hook.cc
+++ b/test/asan/TestCases/malloc_hook.cc
diff --git a/lib/asan/lit_tests/TestCases/max_redzone.cc b/test/asan/TestCases/max_redzone.cc
index dbcedd044..dbcedd044 100644
--- a/lib/asan/lit_tests/TestCases/max_redzone.cc
+++ b/test/asan/TestCases/max_redzone.cc
diff --git a/lib/asan/lit_tests/TestCases/memcmp_strict_test.cc b/test/asan/TestCases/memcmp_strict_test.cc
index e06a8c7e9..e06a8c7e9 100644
--- a/lib/asan/lit_tests/TestCases/memcmp_strict_test.cc
+++ b/test/asan/TestCases/memcmp_strict_test.cc
diff --git a/lib/asan/lit_tests/TestCases/memcmp_test.cc b/test/asan/TestCases/memcmp_test.cc
index 758311ddc..758311ddc 100644
--- a/lib/asan/lit_tests/TestCases/memcmp_test.cc
+++ b/test/asan/TestCases/memcmp_test.cc
diff --git a/lib/asan/lit_tests/TestCases/no_asan_gen_globals.c b/test/asan/TestCases/no_asan_gen_globals.c
index a747d7a36..a747d7a36 100644
--- a/lib/asan/lit_tests/TestCases/no_asan_gen_globals.c
+++ b/test/asan/TestCases/no_asan_gen_globals.c
diff --git a/lib/asan/lit_tests/TestCases/null_deref.cc b/test/asan/TestCases/null_deref.cc
index bae356ae1..bae356ae1 100644
--- a/lib/asan/lit_tests/TestCases/null_deref.cc
+++ b/test/asan/TestCases/null_deref.cc
diff --git a/lib/asan/lit_tests/TestCases/on_error_callback.cc b/test/asan/TestCases/on_error_callback.cc
index d0cec2eb2..d0cec2eb2 100644
--- a/lib/asan/lit_tests/TestCases/on_error_callback.cc
+++ b/test/asan/TestCases/on_error_callback.cc
diff --git a/lib/asan/lit_tests/TestCases/partial_right.cc b/test/asan/TestCases/partial_right.cc
index a000a913d..a000a913d 100644
--- a/lib/asan/lit_tests/TestCases/partial_right.cc
+++ b/test/asan/TestCases/partial_right.cc
diff --git a/lib/asan/lit_tests/TestCases/poison_partial.cc b/test/asan/TestCases/poison_partial.cc
index f7c48bf59..f7c48bf59 100644
--- a/lib/asan/lit_tests/TestCases/poison_partial.cc
+++ b/test/asan/TestCases/poison_partial.cc
diff --git a/lib/asan/lit_tests/TestCases/print-stack-trace.cc b/test/asan/TestCases/print-stack-trace.cc
index 923fa6580..923fa6580 100644
--- a/lib/asan/lit_tests/TestCases/print-stack-trace.cc
+++ b/test/asan/TestCases/print-stack-trace.cc
diff --git a/lib/asan/lit_tests/TestCases/print_summary.cc b/test/asan/TestCases/print_summary.cc
index 949c9b54f..949c9b54f 100644
--- a/lib/asan/lit_tests/TestCases/print_summary.cc
+++ b/test/asan/TestCases/print_summary.cc
diff --git a/lib/asan/lit_tests/TestCases/printf-1.c b/test/asan/TestCases/printf-1.c
index 20618a250..20618a250 100644
--- a/lib/asan/lit_tests/TestCases/printf-1.c
+++ b/test/asan/TestCases/printf-1.c
diff --git a/lib/asan/lit_tests/TestCases/printf-2.c b/test/asan/TestCases/printf-2.c
index a31d2e56a..a31d2e56a 100644
--- a/lib/asan/lit_tests/TestCases/printf-2.c
+++ b/test/asan/TestCases/printf-2.c
diff --git a/lib/asan/lit_tests/TestCases/printf-3.c b/test/asan/TestCases/printf-3.c
index 12ecc6485..12ecc6485 100644
--- a/lib/asan/lit_tests/TestCases/printf-3.c
+++ b/test/asan/TestCases/printf-3.c
diff --git a/lib/asan/lit_tests/TestCases/printf-4.c b/test/asan/TestCases/printf-4.c
index e93c60ca9..e93c60ca9 100644
--- a/lib/asan/lit_tests/TestCases/printf-4.c
+++ b/test/asan/TestCases/printf-4.c
diff --git a/lib/asan/lit_tests/TestCases/printf-5.c b/test/asan/TestCases/printf-5.c
index 5e90e734f..5e90e734f 100644
--- a/lib/asan/lit_tests/TestCases/printf-5.c
+++ b/test/asan/TestCases/printf-5.c
diff --git a/lib/asan/lit_tests/TestCases/readv.cc b/test/asan/TestCases/readv.cc
index ba17505f3..ba17505f3 100644
--- a/lib/asan/lit_tests/TestCases/readv.cc
+++ b/test/asan/TestCases/readv.cc
diff --git a/lib/asan/lit_tests/TestCases/sanity_check_pure_c.c b/test/asan/TestCases/sanity_check_pure_c.c
index df150675b..df150675b 100644
--- a/lib/asan/lit_tests/TestCases/sanity_check_pure_c.c
+++ b/test/asan/TestCases/sanity_check_pure_c.c
diff --git a/lib/asan/lit_tests/TestCases/shared-lib-test.cc b/test/asan/TestCases/shared-lib-test.cc
index 126903a55..126903a55 100644
--- a/lib/asan/lit_tests/TestCases/shared-lib-test.cc
+++ b/test/asan/TestCases/shared-lib-test.cc
diff --git a/lib/asan/lit_tests/TestCases/sleep_before_dying.c b/test/asan/TestCases/sleep_before_dying.c
index 8dee9f277..8dee9f277 100644
--- a/lib/asan/lit_tests/TestCases/sleep_before_dying.c
+++ b/test/asan/TestCases/sleep_before_dying.c
diff --git a/lib/asan/lit_tests/TestCases/stack-buffer-overflow-with-position.cc b/test/asan/TestCases/stack-buffer-overflow-with-position.cc
index 7fbe5c595..7fbe5c595 100644
--- a/lib/asan/lit_tests/TestCases/stack-buffer-overflow-with-position.cc
+++ b/test/asan/TestCases/stack-buffer-overflow-with-position.cc
diff --git a/lib/asan/lit_tests/TestCases/stack-frame-demangle.cc b/test/asan/TestCases/stack-frame-demangle.cc
index 2b83ecc29..2b83ecc29 100644
--- a/lib/asan/lit_tests/TestCases/stack-frame-demangle.cc
+++ b/test/asan/TestCases/stack-frame-demangle.cc
diff --git a/lib/asan/lit_tests/TestCases/stack-oob-frames.cc b/test/asan/TestCases/stack-oob-frames.cc
index 909e700b3..909e700b3 100644
--- a/lib/asan/lit_tests/TestCases/stack-oob-frames.cc
+++ b/test/asan/TestCases/stack-oob-frames.cc
diff --git a/lib/asan/lit_tests/TestCases/stack-overflow.cc b/test/asan/TestCases/stack-overflow.cc
index adf1c0784..adf1c0784 100644
--- a/lib/asan/lit_tests/TestCases/stack-overflow.cc
+++ b/test/asan/TestCases/stack-overflow.cc
diff --git a/lib/asan/lit_tests/TestCases/stack-use-after-return.cc b/test/asan/TestCases/stack-use-after-return.cc
index 75313d4c7..75313d4c7 100644
--- a/lib/asan/lit_tests/TestCases/stack-use-after-return.cc
+++ b/test/asan/TestCases/stack-use-after-return.cc
diff --git a/lib/asan/lit_tests/TestCases/start-deactivated.cc b/test/asan/TestCases/start-deactivated.cc
index a06976649..a06976649 100644
--- a/lib/asan/lit_tests/TestCases/start-deactivated.cc
+++ b/test/asan/TestCases/start-deactivated.cc
diff --git a/lib/asan/lit_tests/TestCases/strdup_oob_test.cc b/test/asan/TestCases/strdup_oob_test.cc
index e92afd3ca..e92afd3ca 100644
--- a/lib/asan/lit_tests/TestCases/strdup_oob_test.cc
+++ b/test/asan/TestCases/strdup_oob_test.cc
diff --git a/lib/asan/lit_tests/TestCases/strerror_r_test.cc b/test/asan/TestCases/strerror_r_test.cc
index d91ad3320..d91ad3320 100644
--- a/lib/asan/lit_tests/TestCases/strerror_r_test.cc
+++ b/test/asan/TestCases/strerror_r_test.cc
diff --git a/lib/asan/lit_tests/TestCases/strip_path_prefix.c b/test/asan/TestCases/strip_path_prefix.c
index c4d6ba49d..c4d6ba49d 100644
--- a/lib/asan/lit_tests/TestCases/strip_path_prefix.c
+++ b/test/asan/TestCases/strip_path_prefix.c
diff --git a/lib/asan/lit_tests/TestCases/strncpy-overflow.cc b/test/asan/TestCases/strncpy-overflow.cc
index f91e191fd..f91e191fd 100644
--- a/lib/asan/lit_tests/TestCases/strncpy-overflow.cc
+++ b/test/asan/TestCases/strncpy-overflow.cc
diff --git a/lib/asan/lit_tests/TestCases/throw_call_test.cc b/test/asan/TestCases/throw_call_test.cc
index 3a97a94b6..3a97a94b6 100644
--- a/lib/asan/lit_tests/TestCases/throw_call_test.cc
+++ b/test/asan/TestCases/throw_call_test.cc
diff --git a/lib/asan/lit_tests/TestCases/throw_catch.cc b/test/asan/TestCases/throw_catch.cc
index 593a26981..593a26981 100644
--- a/lib/asan/lit_tests/TestCases/throw_catch.cc
+++ b/test/asan/TestCases/throw_catch.cc
diff --git a/lib/asan/lit_tests/TestCases/throw_invoke_test.cc b/test/asan/TestCases/throw_invoke_test.cc
index 077a940e8..077a940e8 100644
--- a/lib/asan/lit_tests/TestCases/throw_invoke_test.cc
+++ b/test/asan/TestCases/throw_invoke_test.cc
diff --git a/lib/asan/lit_tests/TestCases/time_interceptor.cc b/test/asan/TestCases/time_interceptor.cc
index 3be00d60c..3be00d60c 100644
--- a/lib/asan/lit_tests/TestCases/time_interceptor.cc
+++ b/test/asan/TestCases/time_interceptor.cc
diff --git a/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc b/test/asan/TestCases/uar_and_exceptions.cc
index c967531c2..c967531c2 100644
--- a/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc
+++ b/test/asan/TestCases/uar_and_exceptions.cc
diff --git a/lib/asan/lit_tests/TestCases/unaligned_loads_and_stores.cc b/test/asan/TestCases/unaligned_loads_and_stores.cc
index d50566c44..d50566c44 100644
--- a/lib/asan/lit_tests/TestCases/unaligned_loads_and_stores.cc
+++ b/test/asan/TestCases/unaligned_loads_and_stores.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-free-right.cc b/test/asan/TestCases/use-after-free-right.cc
index 88d91f53d..88d91f53d 100644
--- a/lib/asan/lit_tests/TestCases/use-after-free-right.cc
+++ b/test/asan/TestCases/use-after-free-right.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-free.cc b/test/asan/TestCases/use-after-free.cc
index 4f31422be..4f31422be 100644
--- a/lib/asan/lit_tests/TestCases/use-after-free.cc
+++ b/test/asan/TestCases/use-after-free.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-poison.cc b/test/asan/TestCases/use-after-poison.cc
index e3bc6ecee..e3bc6ecee 100644
--- a/lib/asan/lit_tests/TestCases/use-after-poison.cc
+++ b/test/asan/TestCases/use-after-poison.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-scope-dtor-order.cc b/test/asan/TestCases/use-after-scope-dtor-order.cc
index 32fa6ad8a..32fa6ad8a 100644
--- a/lib/asan/lit_tests/TestCases/use-after-scope-dtor-order.cc
+++ b/test/asan/TestCases/use-after-scope-dtor-order.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-scope-inlined.cc b/test/asan/TestCases/use-after-scope-inlined.cc
index 0bad048e3..0bad048e3 100644
--- a/lib/asan/lit_tests/TestCases/use-after-scope-inlined.cc
+++ b/test/asan/TestCases/use-after-scope-inlined.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-scope-nobug.cc b/test/asan/TestCases/use-after-scope-nobug.cc
index c23acf76e..c23acf76e 100644
--- a/lib/asan/lit_tests/TestCases/use-after-scope-nobug.cc
+++ b/test/asan/TestCases/use-after-scope-nobug.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-scope-temp.cc b/test/asan/TestCases/use-after-scope-temp.cc
index 13d714f9d..13d714f9d 100644
--- a/lib/asan/lit_tests/TestCases/use-after-scope-temp.cc
+++ b/test/asan/TestCases/use-after-scope-temp.cc
diff --git a/lib/asan/lit_tests/TestCases/use-after-scope.cc b/test/asan/TestCases/use-after-scope.cc
index c46c9594c..c46c9594c 100644
--- a/lib/asan/lit_tests/TestCases/use-after-scope.cc
+++ b/test/asan/TestCases/use-after-scope.cc
diff --git a/lib/asan/lit_tests/TestCases/wait.cc b/test/asan/TestCases/wait.cc
index 730221b32..730221b32 100644
--- a/lib/asan/lit_tests/TestCases/wait.cc
+++ b/test/asan/TestCases/wait.cc
diff --git a/lib/asan/lit_tests/TestCases/waitid.cc b/test/asan/TestCases/waitid.cc
index 386e7108e..386e7108e 100644
--- a/lib/asan/lit_tests/TestCases/waitid.cc
+++ b/test/asan/TestCases/waitid.cc
diff --git a/lib/asan/lit_tests/Unit/lit.site.cfg.in b/test/asan/Unit/lit.site.cfg.in
index f6d9ed94d..96cfc386a 100644
--- a/lib/asan/lit_tests/Unit/lit.site.cfg.in
+++ b/test/asan/Unit/lit.site.cfg.in
@@ -9,7 +9,8 @@ config.name = 'AddressSanitizer-Unit'
# Setup test source and exec root. For unit tests, we define
# it as build directory with ASan unit tests.
-config.test_exec_root = "@ASAN_BINARY_DIR@/tests"
+# FIXME: De-hardcode this path.
+config.test_exec_root = "@COMPILER_RT_BINARY_DIR@/lib/asan/tests"
config.test_source_root = config.test_exec_root
# Enable leak detection in ASan unit tests on x86_64-linux.
diff --git a/lib/asan/lit_tests/android_commands/android_common.py b/test/asan/android_commands/android_common.py
index 43ac7b48d..43ac7b48d 100644
--- a/lib/asan/lit_tests/android_commands/android_common.py
+++ b/test/asan/android_commands/android_common.py
diff --git a/lib/asan/lit_tests/android_commands/android_compile.py b/test/asan/android_commands/android_compile.py
index 4b880886b..4b880886b 100755
--- a/lib/asan/lit_tests/android_commands/android_compile.py
+++ b/test/asan/android_commands/android_compile.py
diff --git a/lib/asan/lit_tests/android_commands/android_run.py b/test/asan/android_commands/android_run.py
index a6ceeb427..a6ceeb427 100755
--- a/lib/asan/lit_tests/android_commands/android_run.py
+++ b/test/asan/android_commands/android_run.py
diff --git a/lib/asan/lit_tests/lit.cfg b/test/asan/lit.cfg
index de18cd669..4fa796bfb 100644
--- a/lib/asan/lit_tests/lit.cfg
+++ b/test/asan/lit.cfg
@@ -2,8 +2,6 @@
import os
-import lit.util
-
def get_required_attr(config, attr_name):
attr_value = getattr(config, attr_name, None)
if not attr_value:
@@ -19,38 +17,6 @@ config.name = 'AddressSanitizer' + config.name_suffix
# Setup source root.
config.test_source_root = os.path.dirname(__file__)
-def DisplayNoConfigMessage():
- lit_config.fatal("No site specific configuration available! " +
- "Try running your test from the build tree or running " +
- "make check-asan")
-
-# Figure out LLVM source root.
-llvm_src_root = getattr(config, 'llvm_src_root', None)
-if llvm_src_root is None:
- # We probably haven't loaded the site-specific configuration: the user
- # is likely trying to run a test file directly, and the site configuration
- # wasn't created by the build system.
- asan_site_cfg = lit_config.params.get('asan_site_config', None)
- if (asan_site_cfg) and (os.path.exists(asan_site_cfg)):
- lit_config.load_config(config, asan_site_cfg)
- raise SystemExit
-
- # Try to guess the location of site-specific configuration using llvm-config
- # util that can point where the build tree is.
- llvm_config = lit.util.which("llvm-config", config.environment["PATH"])
- if not llvm_config:
- DisplayNoConfigMessage()
-
- # Find out the presumed location of generated site config.
- llvm_obj_root = lit.util.capture(["llvm-config", "--obj-root"]).strip()
- asan_site_cfg = os.path.join(llvm_obj_root, "projects", "compiler-rt",
- "lib", "asan", "lit_tests", "lit.site.cfg")
- if (not asan_site_cfg) or (not os.path.exists(asan_site_cfg)):
- DisplayNoConfigMessage()
-
- lit_config.load_config(config, asan_site_cfg)
- raise SystemExit
-
# Setup default compiler flags used with -fsanitize=address option.
# FIXME: Review the set of required flags and check if it can be reduced.
target_cflags = " " + config.target_cflags
@@ -62,9 +28,10 @@ clang_asan_cflags = (" -fsanitize=address"
+ target_cflags)
clang_asan_cxxflags = " --driver-mode=g++" + clang_asan_cflags
+asan_lit_source_dir = get_required_attr(config, "asan_lit_source_dir")
if config.android == "TRUE":
config.available_features.add('android')
- clang_wrapper = os.path.join(config.asan_source_dir, "lit_tests",
+ clang_wrapper = os.path.join(asan_lit_source_dir,
"android_commands", "android_compile.py") + " "
else:
clang_wrapper = ""
@@ -79,8 +46,10 @@ config.substitutions.append( ("%clangxx_asan ", (" " + clang_wrapper + config.cl
clang_asan_cxxflags + " ")) )
+# FIXME: De-hardcode this path.
+asan_source_dir = os.path.join(
+ get_required_attr(config, "compiler_rt_src_root"), "lib", "asan")
# Setup path to asan_symbolize.py script.
-asan_source_dir = get_required_attr(config, "asan_source_dir")
asan_symbolize = os.path.join(asan_source_dir, "scripts", "asan_symbolize.py")
if not os.path.exists(asan_symbolize):
lit_config.fatal("Can't find script on path %r" % asan_symbolize)