diff options
author | Louis Dionne <ldionne.2@gmail.com> | 2023-07-04 18:11:16 -0400 |
---|---|---|
committer | Louis Dionne <ldionne.2@gmail.com> | 2023-07-17 16:06:46 -0400 |
commit | 71f95ecff27e4032ff1c5d196230b42f76a6eb5f (patch) | |
tree | 2543a6234f744d16214088e0973725ac0c312907 /libcxx | |
parent | d4a5470d8c4075045392397b016d4ca60def5da3 (diff) | |
download | llvm-71f95ecff27e4032ff1c5d196230b42f76a6eb5f.zip llvm-71f95ecff27e4032ff1c5d196230b42f76a6eb5f.tar.gz llvm-71f95ecff27e4032ff1c5d196230b42f76a6eb5f.tar.bz2 |
[libc++] Move _LIBCPP_NO_THREAD_SAFETY_ANALYSIS to __config
This makes __threading_support contain nothing but the base threading
API provided by the system.
Differential Revision: https://reviews.llvm.org/D155458
Diffstat (limited to 'libcxx')
-rw-r--r-- | libcxx/include/__config | 6 | ||||
-rw-r--r-- | libcxx/include/__threading_support | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/libcxx/include/__config b/libcxx/include/__config index 5aa56bfb..56e2827 100644 --- a/libcxx/include/__config +++ b/libcxx/include/__config @@ -1137,6 +1137,12 @@ __sanitizer_verify_double_ended_contiguous_container(const void*, const void*, c # define _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK # endif +# if defined(__FreeBSD__) && defined(__clang__) && __has_attribute(__no_thread_safety_analysis__) +# define _LIBCPP_NO_THREAD_SAFETY_ANALYSIS __attribute__((__no_thread_safety_analysis__)) +# else +# define _LIBCPP_NO_THREAD_SAFETY_ANALYSIS +# endif + # if defined(_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS) # if defined(__clang__) && __has_attribute(acquire_capability) // Work around the attribute handling in clang. When both __declspec and diff --git a/libcxx/include/__threading_support b/libcxx/include/__threading_support index 97df18b..3abb3b0 100644 --- a/libcxx/include/__threading_support +++ b/libcxx/include/__threading_support @@ -42,12 +42,6 @@ #define _LIBCPP_THREAD_ABI_VISIBILITY inline _LIBCPP_INLINE_VISIBILITY #endif -#if defined(__FreeBSD__) && defined(__clang__) && __has_attribute(no_thread_safety_analysis) -#define _LIBCPP_NO_THREAD_SAFETY_ANALYSIS __attribute__((no_thread_safety_analysis)) -#else -#define _LIBCPP_NO_THREAD_SAFETY_ANALYSIS -#endif - typedef ::timespec __libcpp_timespec_t; #endif // !defined(_LIBCPP_HAS_NO_THREADS) |