[libcxx-commits] [PATCH] D64378: [libcxx] Use C11 thread API on Fuchsia
Petr Hosek via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Jul 9 18:34:33 PDT 2019
phosek added inline comments.
================
Comment at: libcxx/include/__config:1068
# if defined(__FreeBSD__) || \
- defined(__Fuchsia__) || \
defined(__wasi__) || \
----------------
EricWF wrote:
> Switching the implementation used by Fuchsia is ABI breaking. Are we 100% certain that all of our Fuchsia users don't expect ABI stability?
Yes, that's fundamental part of Fuchsia's packaging story.
================
Comment at: libcxx/include/__config:1107
#if (defined(_LIBCPP_HAS_THREAD_API_PTHREAD) && defined(__GLIBC__)) \
+ || defined(_LIBCPP_HAS_THREAD_API_FUCHSIA) \
|| defined(_LIBCPP_HAS_THREAD_API_WIN32)
----------------
EricWF wrote:
> Can you point towards the C11 source for `mtx_destroy` and `cnd_destroy`?
I've added guard for Fuchsia since this is implementation of details our libc.
================
Comment at: libcxx/include/__config:1115
// as well.
-#if defined(_LIBCPP_HAS_THREAD_API_WIN32)
+#if defined(_LIBCPP_HAS_THREAD_API_FUCHSIA) || \
+ defined(_LIBCPP_HAS_THREAD_API_WIN32)
----------------
EricWF wrote:
> After switching to the `_LIBCPP_HAS_THREAD_API_C11` this check should include `_LIBCPP_HAS_MUSL_LIBC`, because AFAIK, the trivial destruction property is an implementation detail of MUSL.
I've instead added a check for `defined(__Fuchsia__)`, Fuchsia's libc started as a fork of musl but it has sufficiently diverged at this point that I don't think it's safe to consider it being musl-compatible.
Repository:
rCXX libc++
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D64378/new/
https://reviews.llvm.org/D64378
More information about the libcxx-commits
mailing list