Skip to content

Commit 624db73

Browse files
committed
Use CELERITY_SYCL_IS_DPCPP detection macro instead of __SYCL_COMPILER_VERSION
1 parent a9c3001 commit 624db73

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

test/runtime_tests.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ namespace detail {
366366
buffer<size_t, 1> buf1{1};
367367

368368
SECTION("capturing host accessor into device kernel") {
369-
#if !defined(__SYCL_COMPILER_VERSION) // TODO: This may break when using AdaptiveCpp w/ DPC++ as compiler
369+
#if !CELERITY_SYCL_IS_DPCPP
370370
CHECK_THROWS_WITH(([&] {
371371
q.submit([&](handler& cgh) {
372372
accessor acc0{buf1, cgh, one_to_one{}, write_only_host_task};
@@ -400,7 +400,7 @@ namespace detail {
400400

401401
TEST_CASE_METHOD(test_utils::runtime_fixture, "handler throws when accessing host objects within device tasks", "[handler]") {
402402
queue q;
403-
#if !defined(__SYCL_COMPILER_VERSION) // TODO: This may break when using AdaptiveCpp w/ DPC++ as compiler
403+
#if !CELERITY_SYCL_IS_DPCPP
404404
experimental::host_object<size_t> ho;
405405

406406
CHECK_THROWS_WITH(([&] {
@@ -427,7 +427,7 @@ namespace detail {
427427
accessor acc0{buf0, cgh, one_to_one{}, write_only};
428428
accessor acc1{buf1, cgh, one_to_one{}, write_only};
429429
// DPC++ has its own compile-time check for this, so we can't actually capture anything by reference
430-
#if !defined(__SYCL_COMPILER_VERSION) // TODO: This may break when using AdaptiveCpp w/ DPC++ as compiler
430+
#if !CELERITY_SYCL_IS_DPCPP
431431
cgh.parallel_for(range<1>(1), [acc0, &acc1 /* oops */](item<1>) {
432432
(void)acc0;
433433
(void)acc1;

0 commit comments

Comments
 (0)