diff --git a/libcxx/CMakeLists.txt b/libcxx/CMakeLists.txt --- a/libcxx/CMakeLists.txt +++ b/libcxx/CMakeLists.txt @@ -55,16 +55,7 @@ by users in their own code regardless of this option." OFF) option(LIBCXX_ENABLE_SHARED "Build libc++ as a shared library." ON) option(LIBCXX_ENABLE_STATIC "Build libc++ as a static library." ON) -set(ENABLE_FILESYSTEM_DEFAULT ON) -if (WIN32 AND NOT MINGW) - # Filesystem is buildable for windows, but it requires __int128 helper - # functions, that currently are provided by libgcc or compiler_rt builtins. - # These are available in MinGW environments, but not currently in MSVC - # environments. - set(ENABLE_FILESYSTEM_DEFAULT OFF) -endif() -option(LIBCXX_ENABLE_FILESYSTEM "Build filesystem as part of the main libc++ library" - ${ENABLE_FILESYSTEM_DEFAULT}) +option(LIBCXX_ENABLE_FILESYSTEM "Build filesystem as part of the main libc++ library" ON) option(LIBCXX_INCLUDE_TESTS "Build the libc++ tests." ${LLVM_INCLUDE_TESTS}) option(LIBCXX_ENABLE_PARALLEL_ALGORITHMS "Enable the parallel algorithms library. This requires the PSTL to be available." OFF) option(LIBCXX_ENABLE_DEBUG_MODE diff --git a/libcxx/include/__config b/libcxx/include/__config --- a/libcxx/include/__config +++ b/libcxx/include/__config @@ -655,7 +655,7 @@ # define _LIBCPP_PREFERRED_OVERLOAD __attribute__((__enable_if__(true, ""))) # endif -# ifndef __SIZEOF_INT128__ +#if !defined(__SIZEOF_INT128__) || defined(_MSC_VER) # define _LIBCPP_HAS_NO_INT128 # endif diff --git a/libcxx/utils/ci/run-buildbot b/libcxx/utils/ci/run-buildbot --- a/libcxx/utils/ci/run-buildbot +++ b/libcxx/utils/ci/run-buildbot @@ -98,19 +98,10 @@ } function generate-cmake-libcxx-win() { - # TODO: Clang-cl in MSVC configurations don't have access to compiler_rt - # builtins helpers for int128 division. See - # https://reviews.llvm.org/D91139#2429595 for a comment about longterm - # intent for handling the issue. In the meantime, define - # -D_LIBCPP_HAS_NO_INT128 (both when building the library itself and - # when building tests) to allow enabling filesystem for running tests, - # even if it uses a non-permanent ABI. generate-cmake-base \ -DLLVM_ENABLE_RUNTIMES="libcxx" \ -DCMAKE_C_COMPILER=clang-cl \ -DCMAKE_CXX_COMPILER=clang-cl \ - -DLIBCXX_ENABLE_FILESYSTEM=YES \ - -DLIBCXX_EXTRA_SITE_DEFINES="_LIBCPP_HAS_NO_INT128" \ "${@}" }