[libcxx-commits] [libcxx] 87dd519 - [libc++] Remove support for CloudABI, which has been abandoned

Louis Dionne via libcxx-commits libcxx-commits at lists.llvm.org
Tue Aug 24 11:11:36 PDT 2021


Author: Louis Dionne
Date: 2021-08-24T14:11:32-04:00
New Revision: 87dd51983cf91e6db8e1975b7984a4902728470e

URL: https://github.com/llvm/llvm-project/commit/87dd51983cf91e6db8e1975b7984a4902728470e
DIFF: https://github.com/llvm/llvm-project/commit/87dd51983cf91e6db8e1975b7984a4902728470e.diff

LOG: [libc++] Remove support for CloudABI, which has been abandoned

Based on https://github.com/NuxiNL/cloudlibc, it appears that the CloudABI
project has been abandoned. This patch removes a bunch of CloudABI specific
logic that had been added to support that platform.

Note that some knobs like LIBCXX_ENABLE_STDIN and LIBCXX_ENABLE_STDOUT
coud be useful in their own right, however those are currently broken.
If we want to re-add such knobs in the future, we can do it like we've
done it for localization & friends so that we can officially support
that configuration.

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

Added: 
    

Modified: 
    libcxx/CMakeLists.txt
    libcxx/docs/DesignDocs/CapturingConfigInfo.rst
    libcxx/include/__config
    libcxx/include/__config_site.in
    libcxx/include/clocale
    libcxx/include/cstdio
    libcxx/include/cstring
    libcxx/include/ctime
    libcxx/include/cwchar
    libcxx/include/fstream
    libcxx/include/iostream
    libcxx/include/locale
    libcxx/src/iostream.cpp
    libcxx/test/std/depr/depr.c.headers/string_h.pass.cpp
    libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp
    libcxx/test/std/input.output/file.streams/c.files/cstdio.pass.cpp
    libcxx/test/std/input.output/iostream.objects/init.pass.cpp
    libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp
    libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp
    libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp
    libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp
    libcxx/test/std/language.support/support.runtime/ctime.pass.cpp
    libcxx/test/std/localization/c.locales/clocale.pass.cpp
    libcxx/test/std/strings/c.strings/cstring.pass.cpp
    libcxx/test/std/strings/c.strings/cwchar.pass.cpp
    libcxx/test/support/platform_support.h
    libcxx/utils/libcxx/test/features.py

Removed: 
    libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/fopen.compile.fail.cpp
    libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/rename.compile.fail.cpp
    libcxx/test/libcxx/utilities/time/date.time/asctime.thread-unsafe.compile.fail.cpp
    libcxx/test/libcxx/utilities/time/date.time/ctime.thread-unsafe.compile.fail.cpp
    libcxx/test/libcxx/utilities/time/date.time/gmtime.thread-unsafe.compile.fail.cpp
    libcxx/test/libcxx/utilities/time/date.time/localtime.thread-unsafe.compile.fail.cpp
    libcxx/test/std/input.output/file.streams/fstreams/lit.local.cfg
    libcxx/test/std/localization/locales/locale.convenience/conversions/conversions.buffer/lit.local.cfg


################################################################################
diff  --git a/libcxx/CMakeLists.txt b/libcxx/CMakeLists.txt
index 93827cf57b103..0f4c886604c57 100644
--- a/libcxx/CMakeLists.txt
+++ b/libcxx/CMakeLists.txt
@@ -263,11 +263,7 @@ set(LIBCXX_GCC_TOOLCHAIN "" CACHE STRING "Use alternate GCC toolchain.")
 # Feature options -------------------------------------------------------------
 option(LIBCXX_ENABLE_EXCEPTIONS "Use exceptions." ON)
 option(LIBCXX_ENABLE_RTTI "Use run time type information." ON)
-option(LIBCXX_ENABLE_GLOBAL_FILESYSTEM_NAMESPACE "Build libc++ with support for the global filesystem namespace." ON)
-option(LIBCXX_ENABLE_STDIN "Build libc++ with support for stdin/std::cin." ON)
-option(LIBCXX_ENABLE_STDOUT "Build libc++ with support for stdout/std::cout." ON)
 option(LIBCXX_ENABLE_THREADS "Build libc++ with support for threads." ON)
-option(LIBCXX_ENABLE_THREAD_UNSAFE_C_FUNCTIONS "Build libc++ with support for thread-unsafe C functions" ON)
 option(LIBCXX_ENABLE_MONOTONIC_CLOCK
   "Build libc++ with support for a monotonic clock.
    This option may only be set to OFF when LIBCXX_ENABLE_THREADS=OFF." ON)
@@ -868,12 +864,8 @@ config_define_if(LIBCXX_ABI_UNSTABLE _LIBCPP_ABI_UNSTABLE)
 config_define_if(LIBCXX_ABI_FORCE_ITANIUM _LIBCPP_ABI_FORCE_ITANIUM)
 config_define_if(LIBCXX_ABI_FORCE_MICROSOFT _LIBCPP_ABI_FORCE_MICROSOFT)
 config_define_if(LIBCXX_HIDE_FROM_ABI_PER_TU_BY_DEFAULT _LIBCPP_HIDE_FROM_ABI_PER_TU_BY_DEFAULT)
-config_define_if_not(LIBCXX_ENABLE_GLOBAL_FILESYSTEM_NAMESPACE _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE)
-config_define_if_not(LIBCXX_ENABLE_STDIN _LIBCPP_HAS_NO_STDIN)
-config_define_if_not(LIBCXX_ENABLE_STDOUT _LIBCPP_HAS_NO_STDOUT)
 config_define_if_not(LIBCXX_ENABLE_THREADS _LIBCPP_HAS_NO_THREADS)
 config_define_if_not(LIBCXX_ENABLE_MONOTONIC_CLOCK _LIBCPP_HAS_NO_MONOTONIC_CLOCK)
-config_define_if_not(LIBCXX_ENABLE_THREAD_UNSAFE_C_FUNCTIONS _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS)
 if (NOT LIBCXX_TYPEINFO_COMPARISON_IMPLEMENTATION STREQUAL "default")
   config_define("${LIBCXX_TYPEINFO_COMPARISON_IMPLEMENTATION}" _LIBCPP_TYPEINFO_COMPARISON_IMPLEMENTATION)
 endif()

diff  --git a/libcxx/docs/DesignDocs/CapturingConfigInfo.rst b/libcxx/docs/DesignDocs/CapturingConfigInfo.rst
index 8f2d0cd2dd67b..94e1d8b3e7856 100644
--- a/libcxx/docs/DesignDocs/CapturingConfigInfo.rst
+++ b/libcxx/docs/DesignDocs/CapturingConfigInfo.rst
@@ -65,12 +65,8 @@ configuration all together. An example "__config" header generated when
   #ifndef _LIBCPP_CONFIG_SITE
   #define _LIBCPP_CONFIG_SITE
 
-  /* #undef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE */
-  /* #undef _LIBCPP_HAS_NO_STDIN */
-  /* #undef _LIBCPP_HAS_NO_STDOUT */
   #define _LIBCPP_HAS_NO_THREADS
   /* #undef _LIBCPP_HAS_NO_MONOTONIC_CLOCK */
-  /* #undef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS */
 
   #endif
   // -*- C++ -*-

diff  --git a/libcxx/include/__config b/libcxx/include/__config
index 740106ce8d5a2..23a091aa153f6 100644
--- a/libcxx/include/__config
+++ b/libcxx/include/__config
@@ -318,7 +318,7 @@
 #  endif
 #endif // __sun__
 
-#if defined(__OpenBSD__) || defined(__CloudABI__)
+#if defined(__OpenBSD__)
    // Certain architectures provide arc4random(). Prefer using
    // arc4random() over /dev/{u,}random to make it possible to obtain
    // random data even when using sandboxing mechanisms such as chroots,
@@ -935,7 +935,7 @@ typedef unsigned int   char32_t;
 #endif
 
 #if defined(__APPLE__) || defined(__FreeBSD__) || defined(_LIBCPP_MSVCRT_LIKE) || \
-    defined(__sun__) || defined(__NetBSD__) || defined(__CloudABI__)
+    defined(__sun__) || defined(__NetBSD__)
 #define _LIBCPP_LOCALE__L_EXTENSIONS 1
 #endif
 
@@ -1139,7 +1139,6 @@ extern "C" _LIBCPP_FUNC_VIS void __sanitizer_annotate_contiguous_container(
       defined(__linux__) || \
       defined(__GNU__) || \
       defined(__APPLE__) || \
-      defined(__CloudABI__) || \
       defined(__sun__) || \
       defined(__MVS__) || \
       defined(_AIX) || \
@@ -1213,21 +1212,6 @@ extern "C" _LIBCPP_FUNC_VIS void __sanitizer_annotate_contiguous_container(
 # define _LIBCPP_HAS_TRIVIAL_CONDVAR_DESTRUCTION
 #endif
 
-// Systems that use capability-based security (FreeBSD with Capsicum,
-// Nuxi CloudABI) may only provide local filesystem access (using *at()).
-// Functions like open(), rename(), unlink() and stat() should not be
-// used, as they attempt to access the global filesystem namespace.
-#ifdef __CloudABI__
-#define _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
-#endif
-
-// CloudABI is intended for running networked services. Processes do not
-// have standard input and output channels.
-#ifdef __CloudABI__
-#define _LIBCPP_HAS_NO_STDIN
-#define _LIBCPP_HAS_NO_STDOUT
-#endif
-
 // Some systems do not provide gets() in their C library, for security reasons.
 #if defined(_LIBCPP_MSVCRT) || \
     (defined(__FreeBSD_version) && __FreeBSD_version >= 1300043) || \
@@ -1235,18 +1219,12 @@ extern "C" _LIBCPP_FUNC_VIS void __sanitizer_annotate_contiguous_container(
 #   define _LIBCPP_C_HAS_NO_GETS
 #endif
 
-#if defined(__BIONIC__) || defined(__CloudABI__) || defined(__NuttX__) ||      \
+#if defined(__BIONIC__) || defined(__NuttX__) ||      \
     defined(__Fuchsia__) || defined(__wasi__) || defined(_LIBCPP_HAS_MUSL_LIBC) || \
     defined(__MVS__) || defined(__OpenBSD__)
 #define _LIBCPP_PROVIDES_DEFAULT_RUNE_TABLE
 #endif
 
-// Thread-unsafe functions such as strtok() and localtime()
-// are not available.
-#ifdef __CloudABI__
-#define _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
-#endif
-
 #if __has_feature(cxx_atomic) || __has_extension(c_atomic) || __has_keyword(_Atomic)
 #  define _LIBCPP_HAS_C_ATOMIC_IMP
 #elif defined(_LIBCPP_COMPILER_GCC)

diff  --git a/libcxx/include/__config_site.in b/libcxx/include/__config_site.in
index e202d923f31af..c938daae1ed2e 100644
--- a/libcxx/include/__config_site.in
+++ b/libcxx/include/__config_site.in
@@ -14,12 +14,8 @@
 #cmakedefine _LIBCPP_ABI_FORCE_ITANIUM
 #cmakedefine _LIBCPP_ABI_FORCE_MICROSOFT
 #cmakedefine _LIBCPP_HIDE_FROM_ABI_PER_TU_BY_DEFAULT
-#cmakedefine _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
-#cmakedefine _LIBCPP_HAS_NO_STDIN
-#cmakedefine _LIBCPP_HAS_NO_STDOUT
 #cmakedefine _LIBCPP_HAS_NO_THREADS
 #cmakedefine _LIBCPP_HAS_NO_MONOTONIC_CLOCK
-#cmakedefine _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
 #cmakedefine _LIBCPP_HAS_MUSL_LIBC
 #cmakedefine _LIBCPP_HAS_THREAD_API_PTHREAD
 #cmakedefine _LIBCPP_HAS_THREAD_API_EXTERNAL

diff  --git a/libcxx/include/clocale b/libcxx/include/clocale
index 8fe91fc5a3a46..ea4f8014bb2aa 100644
--- a/libcxx/include/clocale
+++ b/libcxx/include/clocale
@@ -44,9 +44,7 @@ lconv* localeconv();
 _LIBCPP_BEGIN_NAMESPACE_STD
 
 using ::lconv _LIBCPP_USING_IF_EXISTS;
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
 using ::setlocale _LIBCPP_USING_IF_EXISTS;
-#endif
 using ::localeconv _LIBCPP_USING_IF_EXISTS;
 
 _LIBCPP_END_NAMESPACE_STD

diff  --git a/libcxx/include/cstdio b/libcxx/include/cstdio
index b480f800a7b45..6a88bee6e8152 100644
--- a/libcxx/include/cstdio
+++ b/libcxx/include/cstdio
@@ -145,30 +145,24 @@ using ::feof _LIBCPP_USING_IF_EXISTS;
 using ::ferror _LIBCPP_USING_IF_EXISTS;
 using ::perror _LIBCPP_USING_IF_EXISTS;
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 using ::fopen _LIBCPP_USING_IF_EXISTS;
 using ::freopen _LIBCPP_USING_IF_EXISTS;
 using ::remove _LIBCPP_USING_IF_EXISTS;
 using ::rename _LIBCPP_USING_IF_EXISTS;
 using ::tmpfile _LIBCPP_USING_IF_EXISTS;
 using ::tmpnam _LIBCPP_USING_IF_EXISTS;
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDIN
 using ::getchar _LIBCPP_USING_IF_EXISTS;
 #if _LIBCPP_STD_VER <= 11 && !defined(_LIBCPP_C_HAS_NO_GETS)
 using ::gets _LIBCPP_USING_IF_EXISTS;
 #endif
 using ::scanf _LIBCPP_USING_IF_EXISTS;
 using ::vscanf _LIBCPP_USING_IF_EXISTS;
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDOUT
 using ::printf _LIBCPP_USING_IF_EXISTS;
 using ::putchar _LIBCPP_USING_IF_EXISTS;
 using ::puts _LIBCPP_USING_IF_EXISTS;
 using ::vprintf _LIBCPP_USING_IF_EXISTS;
-#endif
 
 _LIBCPP_END_NAMESPACE_STD
 

diff  --git a/libcxx/include/cstring b/libcxx/include/cstring
index 34449ab3330b5..d69d27c1a9fd5 100644
--- a/libcxx/include/cstring
+++ b/libcxx/include/cstring
@@ -84,9 +84,7 @@ using ::strpbrk _LIBCPP_USING_IF_EXISTS;
 using ::strrchr _LIBCPP_USING_IF_EXISTS;
 using ::strspn _LIBCPP_USING_IF_EXISTS;
 using ::strstr _LIBCPP_USING_IF_EXISTS;
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
 using ::strtok _LIBCPP_USING_IF_EXISTS;
-#endif
 using ::memset _LIBCPP_USING_IF_EXISTS;
 using ::strerror _LIBCPP_USING_IF_EXISTS;
 using ::strlen _LIBCPP_USING_IF_EXISTS;

diff  --git a/libcxx/include/ctime b/libcxx/include/ctime
index 2a3fdd12e874b..816618f6a373b 100644
--- a/libcxx/include/ctime
+++ b/libcxx/include/ctime
@@ -79,12 +79,10 @@ using ::clock _LIBCPP_USING_IF_EXISTS;
 using ::
diff time _LIBCPP_USING_IF_EXISTS;
 using ::mktime _LIBCPP_USING_IF_EXISTS;
 using ::time _LIBCPP_USING_IF_EXISTS;
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
 using ::asctime _LIBCPP_USING_IF_EXISTS;
 using ::ctime _LIBCPP_USING_IF_EXISTS;
 using ::gmtime _LIBCPP_USING_IF_EXISTS;
 using ::localtime _LIBCPP_USING_IF_EXISTS;
-#endif
 using ::strftime _LIBCPP_USING_IF_EXISTS;
 #if _LIBCPP_STD_VER > 14 && defined(_LIBCPP_HAS_TIMESPEC_GET) && !defined(_LIBCPP_HAS_TIMESPEC_GET_NOT_ACTUALLY_PROVIDED)
 using ::timespec_get _LIBCPP_USING_IF_EXISTS;

diff  --git a/libcxx/include/cwchar b/libcxx/include/cwchar
index f39046f0a9c2c..5de1b62a72d60 100644
--- a/libcxx/include/cwchar
+++ b/libcxx/include/cwchar
@@ -175,17 +175,13 @@ using ::wcrtomb _LIBCPP_USING_IF_EXISTS;
 using ::mbsrtowcs _LIBCPP_USING_IF_EXISTS;
 using ::wcsrtombs _LIBCPP_USING_IF_EXISTS;
 
-#ifndef _LIBCPP_HAS_NO_STDIN
 using ::getwchar _LIBCPP_USING_IF_EXISTS;
 using ::vwscanf _LIBCPP_USING_IF_EXISTS;
 using ::wscanf _LIBCPP_USING_IF_EXISTS;
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDOUT
 using ::putwchar _LIBCPP_USING_IF_EXISTS;
 using ::vwprintf _LIBCPP_USING_IF_EXISTS;
 using ::wprintf _LIBCPP_USING_IF_EXISTS;
-#endif
 
 _LIBCPP_END_NAMESPACE_STD
 

diff  --git a/libcxx/include/fstream b/libcxx/include/fstream
index c522b8ab110d7..6e84614ec1057 100644
--- a/libcxx/include/fstream
+++ b/libcxx/include/fstream
@@ -230,7 +230,6 @@ public:
     // 27.9.1.4 Members:
     _LIBCPP_INLINE_VISIBILITY
     bool is_open() const;
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     basic_filebuf* open(const char* __s, ios_base::openmode __mode);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
     basic_filebuf* open(const wchar_t* __s, ios_base::openmode __mode);
@@ -246,7 +245,6 @@ public:
 #endif
     _LIBCPP_INLINE_VISIBILITY
     basic_filebuf* __open(int __fd, ios_base::openmode __mode);
-#endif
     basic_filebuf* close();
 
     _LIBCPP_INLINE_VISIBILITY
@@ -542,7 +540,6 @@ const char* basic_filebuf<_CharT, _Traits>::__make_mdstring(
   _LIBCPP_UNREACHABLE();
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 basic_filebuf<_CharT, _Traits>*
 basic_filebuf<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode)
@@ -685,7 +682,6 @@ basic_filebuf<_CharT, _Traits>::open(const string& __s, ios_base::openmode __mod
 {
     return open(__s.c_str(), __mode);
 }
-#endif
 
 template <class _CharT, class _Traits>
 basic_filebuf<_CharT, _Traits>*
@@ -1141,7 +1137,6 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     basic_ifstream();
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     _LIBCPP_INLINE_VISIBILITY
     explicit basic_ifstream(const char* __s, ios_base::openmode __mode = ios_base::in);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
@@ -1155,7 +1150,6 @@ public:
     explicit basic_ifstream(const filesystem::path& __p, ios_base::openmode __mode = ios_base::in)
       : basic_ifstream(__p.c_str(), __mode) {}
 #endif // _LIBCPP_STD_VER >= 17
-#endif
     _LIBCPP_INLINE_VISIBILITY
     basic_ifstream(basic_ifstream&& __rhs);
     _LIBCPP_INLINE_VISIBILITY
@@ -1167,7 +1161,6 @@ public:
     basic_filebuf<char_type, traits_type>* rdbuf() const;
     _LIBCPP_INLINE_VISIBILITY
     bool is_open() const;
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     void open(const char* __s, ios_base::openmode __mode = ios_base::in);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
     void open(const wchar_t* __s, ios_base::openmode __mode = ios_base::in);
@@ -1183,7 +1176,6 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     void __open(int __fd, ios_base::openmode __mode);
-#endif
     _LIBCPP_INLINE_VISIBILITY
     void close();
 
@@ -1198,7 +1190,6 @@ basic_ifstream<_CharT, _Traits>::basic_ifstream()
 {
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 inline
 basic_ifstream<_CharT, _Traits>::basic_ifstream(const char* __s, ios_base::openmode __mode)
@@ -1227,7 +1218,6 @@ basic_ifstream<_CharT, _Traits>::basic_ifstream(const string& __s, ios_base::ope
     if (__sb_.open(__s, __mode | ios_base::in) == nullptr)
         this->setstate(ios_base::failbit);
 }
-#endif
 
 template <class _CharT, class _Traits>
 inline
@@ -1281,7 +1271,6 @@ basic_ifstream<_CharT, _Traits>::is_open() const
     return __sb_.is_open();
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 void
 basic_ifstream<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode)
@@ -1323,7 +1312,6 @@ void basic_ifstream<_CharT, _Traits>::__open(int __fd,
   else
     this->setstate(ios_base::failbit);
 }
-#endif
 
 template <class _CharT, class _Traits>
 inline
@@ -1375,7 +1363,6 @@ public:
     basic_filebuf<char_type, traits_type>* rdbuf() const;
     _LIBCPP_INLINE_VISIBILITY
     bool is_open() const;
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     void open(const char* __s, ios_base::openmode __mode = ios_base::out);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
     void open(const wchar_t* __s, ios_base::openmode __mode = ios_base::out);
@@ -1390,7 +1377,6 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     void __open(int __fd, ios_base::openmode __mode);
-#endif
     _LIBCPP_INLINE_VISIBILITY
     void close();
 
@@ -1405,7 +1391,6 @@ basic_ofstream<_CharT, _Traits>::basic_ofstream()
 {
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 inline
 basic_ofstream<_CharT, _Traits>::basic_ofstream(const char* __s, ios_base::openmode __mode)
@@ -1434,7 +1419,6 @@ basic_ofstream<_CharT, _Traits>::basic_ofstream(const string& __s, ios_base::ope
     if (__sb_.open(__s, __mode | ios_base::out) == nullptr)
         this->setstate(ios_base::failbit);
 }
-#endif
 
 template <class _CharT, class _Traits>
 inline
@@ -1488,7 +1472,6 @@ basic_ofstream<_CharT, _Traits>::is_open() const
     return __sb_.is_open();
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 void
 basic_ofstream<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode)
@@ -1530,7 +1513,6 @@ void basic_ofstream<_CharT, _Traits>::__open(int __fd,
   else
     this->setstate(ios_base::failbit);
 }
-#endif
 
 template <class _CharT, class _Traits>
 inline
@@ -1556,7 +1538,6 @@ public:
 
     _LIBCPP_INLINE_VISIBILITY
     basic_fstream();
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     _LIBCPP_INLINE_VISIBILITY
     explicit basic_fstream(const char* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
@@ -1572,7 +1553,6 @@ public:
       : basic_fstream(__p.c_str(), __mode) {}
 #endif // _LIBCPP_STD_VER >= 17
 
-#endif
     _LIBCPP_INLINE_VISIBILITY
     basic_fstream(basic_fstream&& __rhs);
 
@@ -1586,7 +1566,6 @@ public:
     basic_filebuf<char_type, traits_type>* rdbuf() const;
     _LIBCPP_INLINE_VISIBILITY
     bool is_open() const;
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     void open(const char* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
 #ifdef _LIBCPP_HAS_OPEN_WITH_WCHAR
     void open(const wchar_t* __s, ios_base::openmode __mode = ios_base::in | ios_base::out);
@@ -1599,7 +1578,6 @@ public:
     { return open(__p.c_str(), __mode); }
 #endif // _LIBCPP_STD_VER >= 17
 
-#endif
     _LIBCPP_INLINE_VISIBILITY
     void close();
 
@@ -1614,7 +1592,6 @@ basic_fstream<_CharT, _Traits>::basic_fstream()
 {
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 inline
 basic_fstream<_CharT, _Traits>::basic_fstream(const char* __s, ios_base::openmode __mode)
@@ -1643,7 +1620,6 @@ basic_fstream<_CharT, _Traits>::basic_fstream(const string& __s, ios_base::openm
     if (__sb_.open(__s, __mode) == nullptr)
         this->setstate(ios_base::failbit);
 }
-#endif
 
 template <class _CharT, class _Traits>
 inline
@@ -1697,7 +1673,6 @@ basic_fstream<_CharT, _Traits>::is_open() const
     return __sb_.is_open();
 }
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
 template <class _CharT, class _Traits>
 void
 basic_fstream<_CharT, _Traits>::open(const char* __s, ios_base::openmode __mode)
@@ -1729,7 +1704,6 @@ basic_fstream<_CharT, _Traits>::open(const string& __s, ios_base::openmode __mod
     else
         this->setstate(ios_base::failbit);
 }
-#endif
 
 template <class _CharT, class _Traits>
 inline

diff  --git a/libcxx/include/iostream b/libcxx/include/iostream
index 5811fc37c85df..788cfe1c61067 100644
--- a/libcxx/include/iostream
+++ b/libcxx/include/iostream
@@ -45,14 +45,10 @@ extern wostream wclog;
 
 _LIBCPP_BEGIN_NAMESPACE_STD
 
-#ifndef _LIBCPP_HAS_NO_STDIN
 extern _LIBCPP_FUNC_VIS istream cin;
 extern _LIBCPP_FUNC_VIS wistream wcin;
-#endif
-#ifndef _LIBCPP_HAS_NO_STDOUT
 extern _LIBCPP_FUNC_VIS ostream cout;
 extern _LIBCPP_FUNC_VIS wostream wcout;
-#endif
 extern _LIBCPP_FUNC_VIS ostream cerr;
 extern _LIBCPP_FUNC_VIS wostream wcerr;
 extern _LIBCPP_FUNC_VIS ostream clog;

diff  --git a/libcxx/include/locale b/libcxx/include/locale
index 82c27bad6f51e..25cafdd35db3a 100644
--- a/libcxx/include/locale
+++ b/libcxx/include/locale
@@ -230,7 +230,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD
 
 #if defined(__APPLE__) || defined(__FreeBSD__)
 #  define _LIBCPP_GET_C_LOCALE 0
-#elif defined(__CloudABI__) || defined(__NetBSD__)
+#elif defined(__NetBSD__)
 #  define _LIBCPP_GET_C_LOCALE LC_C_LOCALE
 #else
 #  define _LIBCPP_GET_C_LOCALE __cloc()

diff  --git a/libcxx/src/iostream.cpp b/libcxx/src/iostream.cpp
index ea95534c7667a..16e05cf0698cf 100644
--- a/libcxx/src/iostream.cpp
+++ b/libcxx/src/iostream.cpp
@@ -17,7 +17,6 @@
 
 _LIBCPP_BEGIN_NAMESPACE_STD
 
-#ifndef _LIBCPP_HAS_NO_STDIN
 _ALIGNAS_TYPE (istream) _LIBCPP_FUNC_VIS char cin[sizeof(istream)]
 #if defined(_LIBCPP_ABI_MICROSOFT) && defined(__clang__)
 __asm__("?cin@" _LIBCPP_ABI_NAMESPACE_STR "@std@@3V?$basic_istream at DU?$char_traits at D@" _LIBCPP_ABI_NAMESPACE_STR "@std@@@12 at A")
@@ -32,9 +31,7 @@ __asm__("?wcin@" _LIBCPP_ABI_NAMESPACE_STR "@std@@3V?$basic_istream at _WU?$char_tr
 ;
 _ALIGNAS_TYPE (__stdinbuf<wchar_t> ) static char __wcin[sizeof(__stdinbuf <wchar_t>)];
 static mbstate_t mb_wcin;
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDOUT
 _ALIGNAS_TYPE (ostream) _LIBCPP_FUNC_VIS char cout[sizeof(ostream)]
 #if defined(_LIBCPP_ABI_MICROSOFT) && defined(__clang__)
 __asm__("?cout@" _LIBCPP_ABI_NAMESPACE_STR "@std@@3V?$basic_ostream at DU?$char_traits at D@" _LIBCPP_ABI_NAMESPACE_STR "@std@@@12 at A")
@@ -49,7 +46,6 @@ __asm__("?wcout@" _LIBCPP_ABI_NAMESPACE_STR "@std@@3V?$basic_ostream at _WU?$char_t
 ;
 _ALIGNAS_TYPE (__stdoutbuf<wchar_t>) static char __wcout[sizeof(__stdoutbuf<wchar_t>)];
 static mbstate_t mb_wcout;
-#endif
 
 _ALIGNAS_TYPE (ostream) _LIBCPP_FUNC_VIS char cerr[sizeof(ostream)]
 #if defined(_LIBCPP_ABI_MICROSOFT) && defined(__clang__)
@@ -107,39 +103,29 @@ DoIOSInit::DoIOSInit()
 {
     force_locale_initialization();
 
-#ifndef _LIBCPP_HAS_NO_STDIN
     istream* cin_ptr  = ::new(cin)  istream(::new(__cin)  __stdinbuf <char>(stdin, &mb_cin));
     wistream* wcin_ptr  = ::new(wcin)  wistream(::new(__wcin)  __stdinbuf <wchar_t>(stdin, &mb_wcin));
-#endif
-#ifndef _LIBCPP_HAS_NO_STDOUT
     ostream* cout_ptr = ::new(cout) ostream(::new(__cout) __stdoutbuf<char>(stdout, &mb_cout));
     wostream* wcout_ptr = ::new(wcout) wostream(::new(__wcout) __stdoutbuf<wchar_t>(stdout, &mb_wcout));
-#endif
     ostream* cerr_ptr = ::new(cerr) ostream(::new(__cerr) __stdoutbuf<char>(stderr, &mb_cerr));
                         ::new(clog) ostream(cerr_ptr->rdbuf());
     wostream* wcerr_ptr = ::new(wcerr) wostream(::new(__wcerr) __stdoutbuf<wchar_t>(stderr, &mb_wcerr));
                           ::new(wclog) wostream(wcerr_ptr->rdbuf());
 
-#if !defined(_LIBCPP_HAS_NO_STDIN) && !defined(_LIBCPP_HAS_NO_STDOUT)
     cin_ptr->tie(cout_ptr);
     wcin_ptr->tie(wcout_ptr);
-#endif
     _VSTD::unitbuf(*cerr_ptr);
     _VSTD::unitbuf(*wcerr_ptr);
-#ifndef _LIBCPP_HAS_NO_STDOUT
     cerr_ptr->tie(cout_ptr);
     wcerr_ptr->tie(wcout_ptr);
-#endif
 }
 
 DoIOSInit::~DoIOSInit()
 {
-#ifndef _LIBCPP_HAS_NO_STDOUT
     ostream* cout_ptr = reinterpret_cast<ostream*>(cout);
     wostream* wcout_ptr = reinterpret_cast<wostream*>(wcout);
     cout_ptr->flush();
     wcout_ptr->flush();
-#endif
 
     ostream* clog_ptr = reinterpret_cast<ostream*>(clog);
     wostream* wclog_ptr = reinterpret_cast<wostream*>(wclog);

diff  --git a/libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/fopen.compile.fail.cpp b/libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/fopen.compile.fail.cpp
deleted file mode 100644
index 1c2c329c27819..0000000000000
--- a/libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/fopen.compile.fail.cpp
+++ /dev/null
@@ -1,18 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-// REQUIRES: libcpp-has-no-global-filesystem-namespace
-
-#include <cstdio>
-
-int main(int, char**) {
-    // fopen is not available on systems without a global filesystem namespace.
-    std::fopen("", "");
-
-  return 0;
-}

diff  --git a/libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/rename.compile.fail.cpp b/libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/rename.compile.fail.cpp
deleted file mode 100644
index 61ef15d17155f..0000000000000
--- a/libcxx/test/libcxx/input.output/file.streams/c.files/no.global.filesystem.namespace/rename.compile.fail.cpp
+++ /dev/null
@@ -1,18 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-// REQUIRES: libcpp-has-no-global-filesystem-namespace
-
-#include <cstdio>
-
-int main(int, char**) {
-    // rename is not available on systems without a global filesystem namespace.
-    std::rename("", "");
-
-  return 0;
-}

diff  --git a/libcxx/test/libcxx/utilities/time/date.time/asctime.thread-unsafe.compile.fail.cpp b/libcxx/test/libcxx/utilities/time/date.time/asctime.thread-unsafe.compile.fail.cpp
deleted file mode 100644
index ed49ac28693e9..0000000000000
--- a/libcxx/test/libcxx/utilities/time/date.time/asctime.thread-unsafe.compile.fail.cpp
+++ /dev/null
@@ -1,19 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-// REQUIRES: libcpp-has-no-thread-unsafe-c-functions
-
-#include <ctime>
-
-int main(int, char**) {
-    // asctime is not thread-safe.
-    std::time_t t = 0;
-    std::asctime(&t);
-
-  return 0;
-}

diff  --git a/libcxx/test/libcxx/utilities/time/date.time/ctime.thread-unsafe.compile.fail.cpp b/libcxx/test/libcxx/utilities/time/date.time/ctime.thread-unsafe.compile.fail.cpp
deleted file mode 100644
index 741de667e9e70..0000000000000
--- a/libcxx/test/libcxx/utilities/time/date.time/ctime.thread-unsafe.compile.fail.cpp
+++ /dev/null
@@ -1,19 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-// REQUIRES: libcpp-has-no-thread-unsafe-c-functions
-
-#include <ctime>
-
-int main(int, char**) {
-    // ctime is not thread-safe.
-    std::time_t t = 0;
-    std::ctime(&t);
-
-  return 0;
-}

diff  --git a/libcxx/test/libcxx/utilities/time/date.time/gmtime.thread-unsafe.compile.fail.cpp b/libcxx/test/libcxx/utilities/time/date.time/gmtime.thread-unsafe.compile.fail.cpp
deleted file mode 100644
index ce7f782036b6e..0000000000000
--- a/libcxx/test/libcxx/utilities/time/date.time/gmtime.thread-unsafe.compile.fail.cpp
+++ /dev/null
@@ -1,19 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-// REQUIRES: libcpp-has-no-thread-unsafe-c-functions
-
-#include <ctime>
-
-int main(int, char**) {
-    // gmtime is not thread-safe.
-    std::time_t t = 0;
-    std::gmtime(&t);
-
-  return 0;
-}

diff  --git a/libcxx/test/libcxx/utilities/time/date.time/localtime.thread-unsafe.compile.fail.cpp b/libcxx/test/libcxx/utilities/time/date.time/localtime.thread-unsafe.compile.fail.cpp
deleted file mode 100644
index 8f803d91c0c84..0000000000000
--- a/libcxx/test/libcxx/utilities/time/date.time/localtime.thread-unsafe.compile.fail.cpp
+++ /dev/null
@@ -1,19 +0,0 @@
-//===----------------------------------------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-// REQUIRES: libcpp-has-no-thread-unsafe-c-functions
-
-#include <ctime>
-
-int main(int, char**) {
-    // localtime is not thread-safe.
-    std::time_t t = 0;
-    std::localtime(&t);
-
-  return 0;
-}

diff  --git a/libcxx/test/std/depr/depr.c.headers/string_h.pass.cpp b/libcxx/test/std/depr/depr.c.headers/string_h.pass.cpp
index dfb852d934ebf..0c254ae08ef25 100644
--- a/libcxx/test/std/depr/depr.c.headers/string_h.pass.cpp
+++ b/libcxx/test/std/depr/depr.c.headers/string_h.pass.cpp
@@ -47,9 +47,7 @@ int main(int, char**)
     ASSERT_SAME_TYPE(size_t,        decltype(strspn(cpc, cpc)));
     ASSERT_SAME_TYPE(char*,         decltype(strstr(cp, cpc)));
     ASSERT_SAME_TYPE(const char*,   decltype(strstr(cpc, cpc)));
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
     ASSERT_SAME_TYPE(char*,         decltype(strtok(cp, cpc)));
-#endif
     ASSERT_SAME_TYPE(void*,         decltype(memset(vp, 0, s)));
     ASSERT_SAME_TYPE(char*,         decltype(strerror(0)));
     ASSERT_SAME_TYPE(size_t,        decltype(strlen(cpc)));

diff  --git a/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp b/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp
index 49979c5a30d5d..de05a2db63539 100644
--- a/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp
+++ b/libcxx/test/std/depr/depr.c.headers/wchar_h.pass.cpp
@@ -115,18 +115,12 @@ int main(int, char**)
     ASSERT_SAME_TYPE(size_t,             decltype(wcrtomb(ns, L' ', &mb)));
     ASSERT_SAME_TYPE(size_t,             decltype(mbsrtowcs(ws, (const char**)0, s, &mb)));
     ASSERT_SAME_TYPE(size_t,             decltype(wcsrtombs(ns, (const wchar_t**)0, s, &mb)));
-
-#ifndef _LIBCPP_HAS_NO_STDIN
     ASSERT_SAME_TYPE(wint_t,             decltype(getwchar()));
     ASSERT_SAME_TYPE(int,                decltype(vwscanf(L"", va)));
     ASSERT_SAME_TYPE(int,                decltype(wscanf(L"")));
-#endif
-
-#ifndef _LIBCPP_HAS_NO_STDOUT
     ASSERT_SAME_TYPE(wint_t,             decltype(putwchar(L' ')));
     ASSERT_SAME_TYPE(int,                decltype(vwprintf(L"", va)));
     ASSERT_SAME_TYPE(int,                decltype(wprintf(L"")));
-#endif
 
     return 0;
 }

diff  --git a/libcxx/test/std/input.output/file.streams/c.files/cstdio.pass.cpp b/libcxx/test/std/input.output/file.streams/c.files/cstdio.pass.cpp
index 008862246fcff..d6dc6b7667eb1 100644
--- a/libcxx/test/std/input.output/file.streams/c.files/cstdio.pass.cpp
+++ b/libcxx/test/std/input.output/file.streams/c.files/cstdio.pass.cpp
@@ -136,16 +136,13 @@ int main(int, char**)
     static_assert((std::is_same<decltype(std::ferror(fp)), int>::value), "");
     static_assert((std::is_same<decltype(std::perror("")), void>::value), "");
 
-#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
     static_assert((std::is_same<decltype(std::fopen("", "")), std::FILE*>::value), "");
     static_assert((std::is_same<decltype(std::freopen("", "", fp)), std::FILE*>::value), "");
     static_assert((std::is_same<decltype(std::remove("")), int>::value), "");
     static_assert((std::is_same<decltype(std::rename("","")), int>::value), "");
     static_assert((std::is_same<decltype(std::tmpfile()), std::FILE*>::value), "");
     static_assert((std::is_same<decltype(std::tmpnam(cp)), char*>::value), "");
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDIN
     static_assert((std::is_same<decltype(std::getchar()), int>::value), "");
 #if TEST_STD_VER <= 11
 #   pragma GCC diagnostic push
@@ -155,14 +152,11 @@ int main(int, char**)
 #endif
     static_assert((std::is_same<decltype(std::scanf(" ")), int>::value), "");
     static_assert((std::is_same<decltype(std::vscanf(" ",va)), int>::value), "");
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDOUT
     static_assert((std::is_same<decltype(std::printf(" ")), int>::value), "");
     static_assert((std::is_same<decltype(std::putchar(0)), int>::value), "");
     static_assert((std::is_same<decltype(std::puts("")), int>::value), "");
     static_assert((std::is_same<decltype(std::vprintf(" ",va)), int>::value), "");
-#endif
 
   return 0;
 }

diff  --git a/libcxx/test/std/input.output/file.streams/fstreams/lit.local.cfg b/libcxx/test/std/input.output/file.streams/fstreams/lit.local.cfg
deleted file mode 100644
index 25ac02ba7c667..0000000000000
--- a/libcxx/test/std/input.output/file.streams/fstreams/lit.local.cfg
+++ /dev/null
@@ -1,2 +0,0 @@
-if 'libcpp-has-no-global-filesystem-namespace' in config.available_features:
-    config.unsupported = True

diff  --git a/libcxx/test/std/input.output/iostream.objects/init.pass.cpp b/libcxx/test/std/input.output/iostream.objects/init.pass.cpp
index d06334d1e85c2..e53228adc3245 100644
--- a/libcxx/test/std/input.output/iostream.objects/init.pass.cpp
+++ b/libcxx/test/std/input.output/iostream.objects/init.pass.cpp
@@ -6,8 +6,6 @@
 //
 //===----------------------------------------------------------------------===//
 
-// UNSUPPORTED: libcpp-has-no-stdin, libcpp-has-no-stdout
-
 // Make sure that the iostreams are initialized before everything else.
 // This has been an issue when statically linking libc++ in some contexts.
 // See https://llvm.org/PR28954 for details.

diff  --git a/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp b/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp
index fbb59be56677a..f4b34289cf511 100644
--- a/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp
+++ b/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp
@@ -6,8 +6,6 @@
 //
 //===----------------------------------------------------------------------===//
 
-// XFAIL: libcpp-has-no-stdin
-
 // <iostream>
 
 // istream cin;

diff  --git a/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp b/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp
index 809f2ce3783cf..b39dd156dc7b9 100644
--- a/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp
+++ b/libcxx/test/std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp
@@ -6,8 +6,6 @@
 //
 //===----------------------------------------------------------------------===//
 
-// XFAIL: libcpp-has-no-stdout
-
 // <iostream>
 
 // istream cout;

diff  --git a/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp b/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp
index ef240c76026e5..aee8d793eb4f3 100644
--- a/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp
+++ b/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp
@@ -6,8 +6,6 @@
 //
 //===----------------------------------------------------------------------===//
 
-// XFAIL: libcpp-has-no-stdin
-
 // <iostream>
 
 // istream wcin;

diff  --git a/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp b/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp
index babdc3b510fd4..5f7b737aa7642 100644
--- a/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp
+++ b/libcxx/test/std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp
@@ -6,7 +6,6 @@
 //
 //===----------------------------------------------------------------------===//
 
-// XFAIL: libcpp-has-no-stdout
 // XFAIL: LIBCXX-WINDOWS-FIXME
 
 // <iostream>

diff  --git a/libcxx/test/std/language.support/support.runtime/ctime.pass.cpp b/libcxx/test/std/language.support/support.runtime/ctime.pass.cpp
index 6c3f36610cdf4..d170dc370ecc9 100644
--- a/libcxx/test/std/language.support/support.runtime/ctime.pass.cpp
+++ b/libcxx/test/std/language.support/support.runtime/ctime.pass.cpp
@@ -41,12 +41,10 @@ int main(int, char**)
     static_assert((std::is_same<decltype(std::
diff time(t,t)), double>::value), "");
     static_assert((std::is_same<decltype(std::mktime(&tm)), std::time_t>::value), "");
     static_assert((std::is_same<decltype(std::time(&t)), std::time_t>::value), "");
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
     static_assert((std::is_same<decltype(std::asctime(&tm)), char*>::value), "");
     static_assert((std::is_same<decltype(std::ctime(&t)), char*>::value), "");
     static_assert((std::is_same<decltype(std::gmtime(&t)), std::tm*>::value), "");
     static_assert((std::is_same<decltype(std::localtime(&t)), std::tm*>::value), "");
-#endif
     char* c1 = 0;
     const char* c2 = 0;
     ((void)c1); // Prevent unused warning

diff  --git a/libcxx/test/std/localization/c.locales/clocale.pass.cpp b/libcxx/test/std/localization/c.locales/clocale.pass.cpp
index 3b53481ccfcd4..e148fff741565 100644
--- a/libcxx/test/std/localization/c.locales/clocale.pass.cpp
+++ b/libcxx/test/std/localization/c.locales/clocale.pass.cpp
@@ -13,8 +13,6 @@
 
 #include "test_macros.h"
 
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
-
 #ifndef LC_ALL
 #error LC_ALL not defined
 #endif
@@ -39,8 +37,6 @@
 #error LC_TIME not defined
 #endif
 
-#endif // !_LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
-
 #ifndef NULL
 #error NULL not defined
 #endif
@@ -49,9 +45,7 @@ int main(int, char**)
 {
     std::lconv lc;
     ((void)lc); // Prevent unused warning
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
     static_assert((std::is_same<decltype(std::setlocale(0, "")), char*>::value), "");
-#endif
     static_assert((std::is_same<decltype(std::localeconv()), std::lconv*>::value), "");
 
   return 0;

diff  --git a/libcxx/test/std/localization/locales/locale.convenience/conversions/conversions.buffer/lit.local.cfg b/libcxx/test/std/localization/locales/locale.convenience/conversions/conversions.buffer/lit.local.cfg
deleted file mode 100644
index 25ac02ba7c667..0000000000000
--- a/libcxx/test/std/localization/locales/locale.convenience/conversions/conversions.buffer/lit.local.cfg
+++ /dev/null
@@ -1,2 +0,0 @@
-if 'libcpp-has-no-global-filesystem-namespace' in config.available_features:
-    config.unsupported = True

diff  --git a/libcxx/test/std/strings/c.strings/cstring.pass.cpp b/libcxx/test/std/strings/c.strings/cstring.pass.cpp
index 3d667ed03a69f..44358abc05629 100644
--- a/libcxx/test/std/strings/c.strings/cstring.pass.cpp
+++ b/libcxx/test/std/strings/c.strings/cstring.pass.cpp
@@ -48,9 +48,7 @@ int main(int, char**)
     ASSERT_SAME_TYPE(std::size_t, decltype(std::strspn(cpc, cpc)));
     ASSERT_SAME_TYPE(char*,       decltype(std::strstr(cp, cpc)));
     ASSERT_SAME_TYPE(const char*, decltype(std::strstr(cpc, cpc)));
-#ifndef _LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS
     ASSERT_SAME_TYPE(char*,       decltype(std::strtok(cp, cpc)));
-#endif
     ASSERT_SAME_TYPE(void*,       decltype(std::memset(vp, 0, s)));
     ASSERT_SAME_TYPE(char*,       decltype(std::strerror(0)));
     ASSERT_SAME_TYPE(std::size_t, decltype(std::strlen(cpc)));

diff  --git a/libcxx/test/std/strings/c.strings/cwchar.pass.cpp b/libcxx/test/std/strings/c.strings/cwchar.pass.cpp
index 6c3da91efd1fa..1d2742bf9260c 100644
--- a/libcxx/test/std/strings/c.strings/cwchar.pass.cpp
+++ b/libcxx/test/std/strings/c.strings/cwchar.pass.cpp
@@ -116,17 +116,13 @@ int main(int, char**)
     ASSERT_SAME_TYPE(std::size_t,        decltype(std::mbsrtowcs(ws, (const char**)0, s, &mb)));
     ASSERT_SAME_TYPE(std::size_t,        decltype(std::wcsrtombs(ns, (const wchar_t**)0, s, &mb)));
 
-#ifndef _LIBCPP_HAS_NO_STDIN
     ASSERT_SAME_TYPE(std::wint_t,        decltype(std::getwchar()));
     ASSERT_SAME_TYPE(int,                decltype(std::vwscanf(L"", va)));
     ASSERT_SAME_TYPE(int,                decltype(std::wscanf(L"")));
-#endif
 
-#ifndef _LIBCPP_HAS_NO_STDOUT
     ASSERT_SAME_TYPE(std::wint_t,        decltype(std::putwchar(L' ')));
     ASSERT_SAME_TYPE(int,                decltype(std::vwprintf(L"", va)));
     ASSERT_SAME_TYPE(int,                decltype(std::wprintf(L"")));
-#endif
 
     return 0;
 }

diff  --git a/libcxx/test/support/platform_support.h b/libcxx/test/support/platform_support.h
index d348221c86a73..83e291df43b65 100644
--- a/libcxx/test/support/platform_support.h
+++ b/libcxx/test/support/platform_support.h
@@ -25,17 +25,6 @@
 #   define LOCALE_fr_CA_ISO8859_1 "fr-CA"
 #   define LOCALE_ru_RU_UTF_8     "ru-RU"
 #   define LOCALE_zh_CN_UTF_8     "zh-CN"
-#elif defined(__CloudABI__)
-    // Timezones are integrated into locales through LC_TIMEZONE_MASK on
-    // CloudABI. LC_ALL_MASK can only be used if a timezone has also been
-    // provided. UTC should be all right.
-#   define LOCALE_en_US           "en_US"
-#   define LOCALE_en_US_UTF_8     "en_US.UTF-8 at UTC"
-#   define LOCALE_fr_FR_UTF_8     "fr_FR.UTF-8 at UTC"
-#   define LOCALE_fr_CA_ISO8859_1 "fr_CA.ISO-8859-1 at UTC"
-#   define LOCALE_cs_CZ_ISO8859_2 "cs_CZ.ISO-8859-2 at UTC"
-#   define LOCALE_ru_RU_UTF_8     "ru_RU.UTF-8 at UTC"
-#   define LOCALE_zh_CN_UTF_8     "zh_CN.UTF-8 at UTC"
 #else
 #   define LOCALE_en_US           "en_US"
 #   define LOCALE_en_US_UTF_8     "en_US.UTF-8"
@@ -71,7 +60,6 @@ extern "C" {
 }
 #endif
 
-#ifndef __CloudABI__
 inline
 std::string get_temp_file_name()
 {
@@ -110,8 +98,6 @@ std::wstring get_wide_temp_file_name()
 }
 #endif // _LIBCPP_HAS_OPEN_WITH_WCHAR
 
-#endif // __CloudABI__
-
 #if defined(_CS_GNU_LIBC_VERSION)
 inline bool glibc_version_less_than(char const* version) {
   std::string test_version = std::string("glibc ") + version;

diff  --git a/libcxx/utils/libcxx/test/features.py b/libcxx/utils/libcxx/test/features.py
index 205a4868d5816..a703b0c97539a 100644
--- a/libcxx/utils/libcxx/test/features.py
+++ b/libcxx/utils/libcxx/test/features.py
@@ -89,11 +89,7 @@
 # `libcpp-xxx-yyy-zzz`. When a macro is defined to a specific value
 # (e.g. `_LIBCPP_ABI_VERSION=2`), the feature is `libcpp-xxx-yyy-zzz=<value>`.
 macros = {
-  '_LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE': 'libcpp-has-no-global-filesystem-namespace',
   '_LIBCPP_HAS_NO_MONOTONIC_CLOCK': 'libcpp-has-no-monotonic-clock',
-  '_LIBCPP_HAS_NO_STDIN': 'libcpp-has-no-stdin',
-  '_LIBCPP_HAS_NO_STDOUT': 'libcpp-has-no-stdout',
-  '_LIBCPP_HAS_NO_THREAD_UNSAFE_C_FUNCTIONS': 'libcpp-has-no-thread-unsafe-c-functions',
   '_LIBCPP_HAS_NO_THREADS': 'libcpp-has-no-threads',
   '_LIBCPP_HAS_THREAD_API_EXTERNAL': 'libcpp-has-thread-api-external',
   '_LIBCPP_HAS_THREAD_API_PTHREAD': 'libcpp-has-thread-api-pthread',


        


More information about the libcxx-commits mailing list