From: Reid Kleckner Date: Wed, 31 Oct 2018 00:20:41 +0000 (+0000) Subject: [asan] Remove flags for clang-cl before it supported EH X-Git-Tag: llvmorg-8.0.0-rc1~5407 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1079d7ccfeccf8344eb799bef392a875693ab353;p=platform%2Fupstream%2Fllvm.git [asan] Remove flags for clang-cl before it supported EH Also remove -Wno-undefined-inline, which needed to work around PR19898, which was fixed. llvm-svn: 345677 --- diff --git a/compiler-rt/cmake/Modules/AddCompilerRT.cmake b/compiler-rt/cmake/Modules/AddCompilerRT.cmake index 4d4222d..c91565f 100644 --- a/compiler-rt/cmake/Modules/AddCompilerRT.cmake +++ b/compiler-rt/cmake/Modules/AddCompilerRT.cmake @@ -371,15 +371,6 @@ append_list_if(COMPILER_RT_DEBUG -DSANITIZER_DEBUG=1 COMPILER_RT_UNITTEST_CFLAGS append_list_if(COMPILER_RT_HAS_WCOVERED_SWITCH_DEFAULT_FLAG -Wno-covered-switch-default COMPILER_RT_UNITTEST_CFLAGS) if(MSVC) - # clang doesn't support exceptions on Windows yet. - list(APPEND COMPILER_RT_UNITTEST_CFLAGS -D_HAS_EXCEPTIONS=0) - - # We should teach clang to understand "#pragma intrinsic", see PR19898. - list(APPEND COMPILER_RT_UNITTEST_CFLAGS -Wno-undefined-inline) - - # Clang doesn't support SEH on Windows yet. - list(APPEND COMPILER_RT_GTEST_CFLAGS -DGTEST_HAS_SEH=0) - # gtest use a lot of stuff marked as deprecated on Windows. list(APPEND COMPILER_RT_GTEST_CFLAGS -Wno-deprecated-declarations) endif() diff --git a/compiler-rt/cmake/base-config-ix.cmake b/compiler-rt/cmake/base-config-ix.cmake index b92e29a..2a44d83 100644 --- a/compiler-rt/cmake/base-config-ix.cmake +++ b/compiler-rt/cmake/base-config-ix.cmake @@ -122,8 +122,6 @@ macro(test_targets) # what version of MSVC to pretend to be so that the STL works. set(MSVC_VERSION_FLAG "") if (MSVC) - # Find and run MSVC (not clang-cl) and get its version. This will tell - # clang-cl what version of MSVC to pretend to be so that the STL works. execute_process(COMMAND "$ENV{VSINSTALLDIR}/VC/bin/cl.exe" OUTPUT_QUIET ERROR_VARIABLE MSVC_COMPAT_VERSION diff --git a/compiler-rt/lib/asan/tests/CMakeLists.txt b/compiler-rt/lib/asan/tests/CMakeLists.txt index 1b70605..9e640d1 100644 --- a/compiler-rt/lib/asan/tests/CMakeLists.txt +++ b/compiler-rt/lib/asan/tests/CMakeLists.txt @@ -68,11 +68,6 @@ if(APPLE) list(APPEND ASAN_UNITTEST_COMMON_LINK_FLAGS ${WEAK_SYMBOL_LINK_FLAGS}) endif() -if(MSVC) - # Disable exceptions on Windows until they work reliably. - list(APPEND ASAN_UNITTEST_COMMON_CFLAGS -fno-exceptions -DGTEST_HAS_SEH=0) -endif() - set(ASAN_BLACKLIST_FILE "${CMAKE_CURRENT_SOURCE_DIR}/asan_test.ignore") set(ASAN_UNITTEST_INSTRUMENTED_CFLAGS ${ASAN_UNITTEST_COMMON_CFLAGS}