Skip to content

Commit 1c86928

Browse files
committed
Check for _CUDA_STD_VERSION instead of _LIBCUDACXX_VERSION
1 parent b7a7c78 commit 1c86928

File tree

23 files changed

+45
-45
lines changed

23 files changed

+45
-45
lines changed

libcudacxx/test/libcudacxx/libcxx/atomics/version.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515

1616
#include "test_macros.h"
1717

18-
#ifndef _LIBCUDACXX_VERSION
19-
# error _LIBCUDACXX_VERSION not defined
18+
#ifndef _CUDA_STD_VERSION
19+
# error _CUDA_STD_VERSION not defined
2020
#endif
2121

2222
int main(int, char**)

libcudacxx/test/libcudacxx/libcxx/utilities/meta/version.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212

1313
#include "test_macros.h"
1414

15-
#ifndef _LIBCUDACXX_VERSION
16-
# error _LIBCUDACXX_VERSION not defined
15+
#ifndef _CUDA_STD_VERSION
16+
# error _CUDA_STD_VERSION not defined
1717
#endif
1818

1919
int main(int, char**)

libcudacxx/test/libcudacxx/std/atomics/atomics.lockfree/isalwayslockfree.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ __host__ __device__ void run()
106106
CHECK_ALWAYS_LOCK_FREE(float);
107107
CHECK_ALWAYS_LOCK_FREE(double);
108108
// CHECK_ALWAYS_LOCK_FREE(long double); // long double is not supported
109-
#if _CCCL_HAS_ATTRIBUTE(vector_size) && defined(_LIBCUDACXX_VERSION) && !_CCCL_CUDA_COMPILATION()
109+
#if _CCCL_HAS_ATTRIBUTE(vector_size) && defined(_CUDA_STD_VERSION) && !_CCCL_CUDA_COMPILATION()
110110
// NOTE: NVCC doesn't support the vector_size attribute in device code.
111111
CHECK_ALWAYS_LOCK_FREE(int __attribute__((vector_size(1 * sizeof(int)))));
112112
CHECK_ALWAYS_LOCK_FREE(int __attribute__((vector_size(2 * sizeof(int)))));
@@ -123,7 +123,7 @@ __host__ __device__ void run()
123123
CHECK_ALWAYS_LOCK_FREE(double __attribute__((vector_size(4 * sizeof(double)))));
124124
CHECK_ALWAYS_LOCK_FREE(double __attribute__((vector_size(16 * sizeof(double)))));
125125
CHECK_ALWAYS_LOCK_FREE(double __attribute__((vector_size(32 * sizeof(double)))));
126-
#endif // _CCCL_HAS_ATTRIBUTE(vector_size) && defined(_LIBCUDACXX_VERSION)
126+
#endif // _CCCL_HAS_ATTRIBUTE(vector_size) && defined(_CUDA_STD_VERSION)
127127
CHECK_ALWAYS_LOCK_FREE(struct Empty{});
128128
CHECK_ALWAYS_LOCK_FREE(struct OneInt { int i; });
129129
CHECK_ALWAYS_LOCK_FREE(struct IntArr2 { int i[2]; });

libcudacxx/test/libcudacxx/std/thread/thread.barrier/version.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515

1616
#include "test_macros.h"
1717

18-
#ifndef _LIBCUDACXX_VERSION
19-
# error _LIBCUDACXX_VERSION not defined
18+
#ifndef _CUDA_STD_VERSION
19+
# error _CUDA_STD_VERSION not defined
2020
#endif
2121

2222
int main(int, char**)

libcudacxx/test/libcudacxx/std/thread/thread.latch/version.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515

1616
#include "test_macros.h"
1717

18-
#ifndef _LIBCUDACXX_VERSION
19-
# error _LIBCUDACXX_VERSION not defined
18+
#ifndef _CUDA_STD_VERSION
19+
# error _CUDA_STD_VERSION not defined
2020
#endif
2121

2222
int main(int, char**)

libcudacxx/test/libcudacxx/std/thread/thread.semaphore/version.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515

1616
#include "test_macros.h"
1717

18-
#ifndef _LIBCUDACXX_VERSION
19-
# error _LIBCUDACXX_VERSION not defined
18+
#ifndef _CUDA_STD_VERSION
19+
# error _CUDA_STD_VERSION not defined
2020
#endif
2121

2222
int main(int, char**)

libcudacxx/test/libcudacxx/std/utilities/function.objects/func.not_fn/not_fn.pass.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -388,11 +388,11 @@ __host__ __device__ void constructor_tests()
388388
assert(ret() == false);
389389
auto ret2 = cuda::std::not_fn(value2);
390390
assert(ret2() == true);
391-
#if defined(_LIBCUDACXX_VERSION)
391+
#if defined(_CUDA_STD_VERSION)
392392
ret = ret2;
393393
assert(ret() == true);
394394
assert(ret2() == true);
395-
#endif // _LIBCUDACXX_VERSION
395+
#endif // _CUDA_STD_VERSION
396396
}
397397
{
398398
using T = MoveAssignableWrapper;
@@ -407,10 +407,10 @@ __host__ __device__ void constructor_tests()
407407
assert(ret() == false);
408408
auto ret2 = cuda::std::not_fn(cuda::std::move(value2));
409409
assert(ret2() == true);
410-
#if defined(_LIBCUDACXX_VERSION)
410+
#if defined(_CUDA_STD_VERSION)
411411
ret = cuda::std::move(ret2);
412412
assert(ret() == true);
413-
#endif // _LIBCUDACXX_VERSION
413+
#endif // _CUDA_STD_VERSION
414414
}
415415
}
416416

libcudacxx/test/libcudacxx/std/utilities/memory/default.allocator/allocator.dtor.pass.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,15 +31,15 @@ int main(int, char**)
3131
{
3232
test<int>();
3333
test<void>();
34-
#ifdef _LIBCUDACXX_VERSION // extension
34+
#ifdef _CUDA_STD_VERSION // extension
3535
test<int const>();
36-
#endif // _LIBCUDACXX_VERSION
36+
#endif // _CUDA_STD_VERSION
3737

3838
static_assert(test<int>());
3939
static_assert(test<void>());
40-
#ifdef _LIBCUDACXX_VERSION // extension
40+
#ifdef _CUDA_STD_VERSION // extension
4141
static_assert(test<int const>());
42-
#endif // _LIBCUDACXX_VERSION
42+
#endif // _CUDA_STD_VERSION
4343

4444
return 0;
4545
}

libcudacxx/test/libcudacxx/std/utilities/memory/default.allocator/allocator_types.pass.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ __host__ __device__ void test()
6464
int main(int, char**)
6565
{
6666
test<char>();
67-
#ifdef _LIBCUDACXX_VERSION
67+
#ifdef _CUDA_STD_VERSION
6868
test<char const>(); // extension
6969
#endif
7070
return 0;

libcudacxx/test/libcudacxx/std/utilities/template.bitset/bitset.members/index_const.pass.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ __host__ __device__ constexpr void test_index_const()
2626
{
2727
assert(v[N / 2] == v.test(N / 2));
2828
}
29-
#if !defined(_LIBCUDACXX_VERSION) || defined(_LIBCUDACXX_ABI_BITSET_span_BOOL_CONST_SUBSCRIPT_RETURN_BOOL)
29+
#if !defined(_CUDA_STD_VERSION) || defined(_LIBCUDACXX_ABI_BITSET_span_BOOL_CONST_SUBSCRIPT_RETURN_BOOL)
3030
static_assert(cuda::std::is_same_v<decltype(v[0]), bool>);
3131
#else
3232
static_assert(cuda::std::is_same_v<decltype(v[0]), typename cuda::std::bitset<N>::const_reference>);
@@ -50,7 +50,7 @@ __host__ __device__ constexpr bool test()
5050
const auto& set = set_;
5151
auto b = set[0];
5252
set_[0] = true;
53-
#if !defined(_LIBCUDACXX_VERSION) || defined(_LIBCUDACXX_ABI_BITSET_span_BOOL_CONST_SUBSCRIPT_RETURN_BOOL)
53+
#if !defined(_CUDA_STD_VERSION) || defined(_LIBCUDACXX_ABI_BITSET_span_BOOL_CONST_SUBSCRIPT_RETURN_BOOL)
5454
assert(!b);
5555
#else
5656
assert(b);

0 commit comments

Comments
 (0)