Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove checks against _LIBCUDACXX_STD_VER < 11 #375

Merged
merged 1 commit into from
Aug 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions libcudacxx/include/cuda/std/detail/libcxx/include/__config
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ extern "C++" {
# endif
#endif // _LIBCUDACXX_STD_VER

#if _LIBCUDACXX_STD_VER < 11
# error libcu++ requires C++11 or later
#endif

#if (defined(_LIBCUDACXX_COMPILER_NVHPC) && defined(__linux__)) \
|| defined(_LIBCUDACXX_COMPILER_NVRTC)
#define __ELF__
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
_LIBCUDACXX_BEGIN_NAMESPACE_STD

#if defined(_LIBCUDACXX_IS_CONSTANT_EVALUATED)
#if (defined(__cuda_std__) && _LIBCUDACXX_STD_VER >= 11) || _LIBCUDACXX_STD_VER > 17
#if defined(__cuda_std__) || _LIBCUDACXX_STD_VER > 17
_LIBCUDACXX_INLINE_VISIBILITY
inline constexpr bool is_constant_evaluated() noexcept {
return _LIBCUDACXX_IS_CONSTANT_EVALUATED();
Expand Down
4 changes: 0 additions & 4 deletions libcudacxx/include/cuda/std/detail/libcxx/include/barrier
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,6 @@ namespace std
# error <barrier> is not supported on this single threaded system
#endif

#if _LIBCUDACXX_STD_VER < 11
# error <barrier> requires C++11 or later
#endif

_LIBCUDACXX_BEGIN_NAMESPACE_STD

struct __empty_completion
Expand Down
4 changes: 0 additions & 4 deletions libcudacxx/include/cuda/std/detail/libcxx/include/latch
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,6 @@ namespace std
# error <latch> is not supported on this single threaded system
#endif

#if _LIBCUDACXX_STD_VER < 11
# error <latch> is requires C++11 or later
#endif

_LIBCUDACXX_BEGIN_NAMESPACE_STD

# if _LIBCUDACXX_CUDA_ABI_VERSION < 3
Expand Down
4 changes: 0 additions & 4 deletions libcudacxx/include/cuda/std/detail/libcxx/include/semaphore
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,6 @@ using binary_semaphore = counting_semaphore<1>;
# error <semaphore> is not supported on this single threaded system
#endif

#if _LIBCUDACXX_STD_VER < 11
# error <semaphore> is requires C++11 or later
#endif

_LIBCUDACXX_BEGIN_NAMESPACE_STD

template<int _Sco, ptrdiff_t __least_max_value>
Expand Down
2 changes: 1 addition & 1 deletion libcudacxx/libcxx/src/atomic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

_LIBCUDACXX_BEGIN_NAMESPACE_STD

#if !defined(_LIBCUDACXX_HAS_NO_THREAD_CONTENTION_TABLE) && (_LIBCUDACXX_STD_VER >= 11)
#if !defined(_LIBCUDACXX_HAS_NO_THREAD_CONTENTION_TABLE)

__libcpp_contention_t __libcpp_contention_state_[ 256 /* < there's no magic in this number */ ];

Expand Down
2 changes: 1 addition & 1 deletion libcudacxx/libcxx/src/barrier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

_LIBCUDACXX_BEGIN_NAMESPACE_STD

#if !defined(_LIBCUDACXX_HAS_NO_TREE_BARRIER) && !defined(_LIBCUDACXX_HAS_NO_THREAD_FAVORITE_BARRIER_INDEX) && (_LIBCUDACXX_STD_VER >= 11)
#if !defined(_LIBCUDACXX_HAS_NO_TREE_BARRIER) && !defined(_LIBCUDACXX_HAS_NO_THREAD_FAVORITE_BARRIER_INDEX)

_LIBCUDACXX_EXPORTED_FROM_ABI
thread_local ptrdiff_t __libcpp_thread_favorite_barrier_index = 0;
Expand Down