From af0f9c5605fef57232087aabcc2dc80a48816082 Mon Sep 17 00:00:00 2001 From: Vladimir Lazarev Date: Thu, 19 Nov 2020 08:16:02 +0300 Subject: [PATCH 1/4] [SYCL][NFC] Remove deprecated variables from LIT Remove use of deprecated environment variables (SYCL_BE, SYCL_DEVICE_TYPE) from LIT framework. Use SYCL_DEVICE_FILTER instead: - update [CPU|GPU|ACC]_RUN_PLACEHOLDER to use SYCL_DEVICE_FILTER; - change values format used to define a backend and a device type to match SYCL_DEVICE_FILTER requirements; - add BE_RUN_PLACEHOLDER to set backend only for tests which require that; - add HOST_RUN_PLACEHOLDER to align configuration with other devices; - on-device/basic_tests/diagnostics/device-check.cpp is not changed because it checks SYCL_DEVICE_FILTER itself and will be removed once the variable is removed. --- sycl/test/CMakeLists.txt | 12 ++--- sycl/test/Unit/lit.cfg.py | 4 +- sycl/test/atomic_ref/accessor.cpp | 2 +- sycl/test/atomic_ref/add.cpp | 2 +- sycl/test/atomic_ref/compare_exchange.cpp | 2 +- sycl/test/atomic_ref/exchange.cpp | 2 +- sycl/test/atomic_ref/load.cpp | 2 +- sycl/test/atomic_ref/max.cpp | 2 +- sycl/test/atomic_ref/min.cpp | 2 +- sycl/test/atomic_ref/store.cpp | 2 +- sycl/test/atomic_ref/sub.cpp | 2 +- .../accessor/accessor_property_list_rt.cpp | 2 +- sycl/test/basic_tests/built-ins.cpp | 2 +- sycl/test/basic_tests/context.cpp | 2 +- sycl/test/basic_tests/device.cpp | 2 +- sycl/test/basic_tests/device_selector.cpp | 2 +- sycl/test/basic_tests/esimd/vadd.cpp | 16 +++--- .../basic_tests/event_async_exception.cpp | 2 +- .../basic_tests/host_image_accessor_read.cpp | 2 +- sycl/test/basic_tests/linear-host-dev.cpp | 2 +- .../basic_tests/parallel_for_range_host.cpp | 2 +- sycl/test/basic_tests/property_list.cpp | 2 +- sycl/test/basic_tests/reduction_ctor.cpp | 2 +- sycl/test/bit_cast/bit_cast.cpp | 2 +- sycl/test/extensions/usm.cpp | 2 +- .../function-pointers/fp-as-kernel-arg.cpp | 2 +- .../pass-fp-through-buffer.cpp | 2 +- sycl/test/functor/functor_inheritance.cpp | 2 +- sycl/test/functor/kernel_functor.cpp | 2 +- .../array-kernel-param-nested-run.cpp | 2 +- .../kernel_param/array-kernel-param-run.cpp | 2 +- .../test/kernel_param/non-standard-layout.cpp | 2 +- .../test/kernel_param/struct_kernel_param.cpp | 2 +- sycl/test/kernel_param/union_kernel_param.cpp | 2 +- sycl/test/lit.cfg.py | 20 +++---- sycl/test/multi_ptr/multi_ptr.cpp | 4 +- sycl/test/multisource/multisource.cpp | 4 +- .../basic_tests/access_to_subset.cpp | 2 +- sycl/test/on-device/basic_tests/boolean.cpp | 2 +- .../on-device/basic_tests/buffer/buffer.cpp | 4 +- .../basic_tests/buffer/buffer_container.cpp | 4 +- .../basic_tests/buffer/buffer_dev_to_dev.cpp | 2 +- .../basic_tests/buffer/buffer_full_copy.cpp | 4 +- .../basic_tests/buffer/subbuffer.cpp | 2 +- .../on-device/basic_tests/device_equality.cpp | 2 +- .../on-device/basic_tests/device_event.cpp | 2 +- .../basic_tests/diagnostics/handler.cpp | 2 +- sycl/test/on-device/basic_tests/event.cpp | 2 +- .../on-device/basic_tests/event_creation.cpp | 2 +- .../basic_tests/event_profiling_info.cpp | 2 +- .../on-device/basic_tests/get_backend.cpp | 3 +- .../basic_tests/get_nonhost_devices.cpp | 2 +- sycl/test/on-device/basic_tests/half_type.cpp | 2 +- .../basic_tests/host_always_works.cpp | 2 +- .../basic_tests/host_platform_avail.cpp | 2 +- sycl/test/on-device/basic_tests/image.cpp | 2 +- .../basic_tests/image/image_read.cpp | 2 +- .../basic_tests/image/image_read_fp16.cpp | 2 +- .../basic_tests/image/image_write.cpp | 2 +- .../basic_tests/image/image_write_fp16.cpp | 2 +- .../image_accessor_readsampler.cpp | 2 +- .../basic_tests/image_accessor_readwrite.cpp | 2 +- .../image_accessor_readwrite_half.cpp | 2 +- .../on-device/basic_tests/image_array.cpp | 2 +- .../basic_tests/image_constructors.cpp | 4 +- sycl/test/on-device/basic_tests/info.cpp | 2 +- .../basic_tests/info_ocl_version.cpp | 2 +- .../basic_tests/parallel_for_indexers.cpp | 4 +- .../basic_tests/scalar_vec_access.cpp | 2 +- .../on-device/basic_tests/stream/stream.cpp | 2 +- sycl/test/on-device/basic_tests/subdevice.cpp | 2 +- .../test/on-device/basic_tests/swizzle_op.cpp | 2 +- .../on-device/basic_tests/sycl-namespace.cpp | 2 +- .../on-device/basic_tests/unused_pointer.cpp | 2 +- sycl/test/on-device/config/select_device.cpp | 54 +++++++++---------- .../dot_product/dot_product_int_test.cpp | 2 +- .../dot_product/dot_product_vec_test.cpp | 2 +- .../on-device/hier_par/hier_par_basic.cpp | 2 +- .../on-device/hier_par/hier_par_wgscope.cpp | 2 +- .../hier_par/hier_par_wgscope_O0.cpp | 2 +- .../test/on-device/plugins/interop-opencl.cpp | 6 +-- .../on-device/plugins/sycl-ls-gpu-cuda.cpp | 2 +- .../on-device/plugins/sycl-ls-gpu-default.cpp | 2 +- .../on-device/plugins/sycl-ls-gpu-opencl.cpp | 2 +- .../on-device/plugins/sycl-ls-gpu-sycl-be.cpp | 4 +- .../on-device/plugins/sycl-targets-order.cpp | 8 +-- .../reduction/reduction_nd_conditional.cpp | 2 +- .../reduction/reduction_nd_ext_double.cpp | 2 +- .../reduction/reduction_nd_ext_half.cpp | 2 +- .../reduction/reduction_nd_lambda.cpp | 2 +- .../reduction/reduction_nd_s0_dw.cpp | 2 +- .../reduction/reduction_nd_s0_rw.cpp | 2 +- .../reduction/reduction_nd_s1_dw.cpp | 2 +- .../reduction/reduction_nd_s1_rw.cpp | 2 +- .../reduction/reduction_placeholder.cpp | 2 +- .../reduction_queue_parallel_for.cpp | 2 +- .../reduction/reduction_transparent.cpp | 2 +- .../on-device/reduction/reduction_usm.cpp | 2 +- .../regression/usm_malloc_shared.cpp | 2 +- .../on-device/spec_const/spec_const_hw.cpp | 2 +- .../on-device/spec_const/spec_const_neg.cpp | 2 +- .../spec_const/spec_const_redefine.cpp | 2 +- sycl/test/on-device/sub_group/attributes.cpp | 2 +- sycl/test/on-device/sub_group/barrier.cpp | 2 +- sycl/test/on-device/sub_group/broadcast.cpp | 2 +- .../on-device/sub_group/broadcast_fp64.cpp | 2 +- sycl/test/on-device/sub_group/common.cpp | 2 +- .../on-device/sub_group/generic-shuffle.cpp | 2 +- .../on-device/sub_group/generic_reduce.cpp | 2 +- sycl/test/on-device/sub_group/info.cpp | 2 +- sycl/test/on-device/sub_group/load_store.cpp | 2 +- sycl/test/on-device/sub_group/reduce.cpp | 2 +- sycl/test/on-device/sub_group/reduce_fp64.cpp | 2 +- sycl/test/on-device/sub_group/scan.cpp | 2 +- sycl/test/on-device/sub_group/scan_fp64.cpp | 2 +- sycl/test/on-device/sub_group/shuffle.cpp | 2 +- .../test/on-device/sub_group/shuffle_fp64.cpp | 2 +- sycl/test/on-device/sub_group/vote.cpp | 2 +- sycl/test/regression/atomic_load.cpp | 2 +- sycl/test/regression/builtins_vector1.cpp | 2 +- .../test/regression/complex_global_object.cpp | 2 +- .../regression/fp16-with-unnamed-lambda.cpp | 2 +- sycl/test/regression/global_queue.cpp | 2 +- sycl/test/regression/group.cpp | 2 +- .../regression/implicit_atomic_conversion.cpp | 2 +- sycl/test/regression/kernel_name_class.cpp | 4 +- .../kernel_name_inside_sycl_namespace.cpp | 2 +- sycl/test/regression/kernel_unnamed.cpp | 2 +- sycl/test/regression/msvc_crt.cpp | 4 +- .../regression/private_array_init_test.cpp | 2 +- sycl/test/regression/same_unnamed_kernels.cpp | 2 +- sycl/test/regression/static-buffer-dtor.cpp | 2 +- sycl/test/regression/sycl-include-gnu11.cpp | 2 +- sycl/test/scheduler/BasicSchedulerTests.cpp | 2 +- sycl/test/scheduler/ReleaseResourcesTest.cpp | 2 +- 135 files changed, 200 insertions(+), 197 deletions(-) diff --git a/sycl/test/CMakeLists.txt b/sycl/test/CMakeLists.txt index 5cd037e21caa7..eaf842a6fb94f 100644 --- a/sycl/test/CMakeLists.txt +++ b/sycl/test/CMakeLists.txt @@ -45,7 +45,7 @@ list(APPEND SYCL_DEPLOY_TEST_DEPS add_lit_testsuite(check-sycl-deploy "Running the SYCL regression tests" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${DEPLOY_RT_TEST_ARGS} - PARAMS "SYCL_BE=PI_OPENCL" + PARAMS "SYCL_BE=opencl" DEPENDS ${SYCL_DEPLOY_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -58,7 +58,7 @@ add_lit_testsuites(SYCL ${CMAKE_CURRENT_SOURCE_DIR} add_lit_testsuites(SYCL-DEPLOY ${CMAKE_CURRENT_SOURCE_DIR} ARGS ${DEPLOY_RT_TEST_ARGS} - PARAMS "SYCL_BE=PI_OPENCL" + PARAMS "SYCL_BE=opencl" DEPENDS ${SYCL_DEPLOY_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -66,7 +66,7 @@ add_lit_testsuites(SYCL-DEPLOY ${CMAKE_CURRENT_SOURCE_DIR} add_lit_testsuite(check-sycl-opencl "Running the SYCL regression tests for OpenCL" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${RT_TEST_ARGS} - PARAMS "SYCL_BE=PI_OPENCL" + PARAMS "SYCL_BE=opencl" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -75,7 +75,7 @@ set_target_properties(check-sycl-opencl PROPERTIES FOLDER "SYCL tests") add_lit_testsuite(check-sycl-level-zero "Running the SYCL regression tests for Level Zero" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${RT_TEST_ARGS} - PARAMS "SYCL_BE=PI_LEVEL_ZERO" + PARAMS "SYCL_BE=level_zero" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -89,7 +89,7 @@ if(SYCL_BUILD_PI_CUDA) add_lit_testsuite(check-sycl-cuda "Running the SYCL regression tests for CUDA" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${RT_TEST_ARGS} - PARAMS "SYCL_BE=PI_CUDA" + PARAMS "SYCL_BE=cuda" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -98,7 +98,7 @@ if(SYCL_BUILD_PI_CUDA) add_dependencies(check-sycl check-sycl-cuda) add_lit_testsuites(SYCL-CUDA ${CMAKE_CURRENT_SOURCE_DIR} - PARAMS "SYCL_BE=PI_CUDA" + PARAMS "SYCL_BE=cuda" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) diff --git a/sycl/test/Unit/lit.cfg.py b/sycl/test/Unit/lit.cfg.py index e97e732996ab7..ed0b0e07a10c0 100644 --- a/sycl/test/Unit/lit.cfg.py +++ b/sycl/test/Unit/lit.cfg.py @@ -73,5 +73,5 @@ def find_shlibpath_var(): lit_config.warning("unable to inject shared library path on '{}'" .format(platform.system())) -config.environment['SYCL_BE'] = lit_config.params.get('SYCL_BE', "PI_OPENCL") -lit_config.note("Backend (SYCL_BE): {}".format(config.environment['SYCL_BE'])) +config.environment['SYCL_DEVICE_FILTER'] = lit_config.params.get('SYCL_BE', "opencl") +lit_config.note("Backend: {}".format(config.environment['SYCL_DEVICE_FILTER'])) diff --git a/sycl/test/atomic_ref/accessor.cpp b/sycl/test/atomic_ref/accessor.cpp index 5e488a578f2bb..ed04aad595e6e 100644 --- a/sycl/test/atomic_ref/accessor.cpp +++ b/sycl/test/atomic_ref/accessor.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/add.cpp b/sycl/test/atomic_ref/add.cpp index decf99a6dec8c..cfcfd25e89b4c 100644 --- a/sycl/test/atomic_ref/add.cpp +++ b/sycl/test/atomic_ref/add.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/compare_exchange.cpp b/sycl/test/atomic_ref/compare_exchange.cpp index 5dce9390c9985..5b84ce62c0fed 100644 --- a/sycl/test/atomic_ref/compare_exchange.cpp +++ b/sycl/test/atomic_ref/compare_exchange.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/exchange.cpp b/sycl/test/atomic_ref/exchange.cpp index 755b40d75c1a3..db9524ec58bd9 100644 --- a/sycl/test/atomic_ref/exchange.cpp +++ b/sycl/test/atomic_ref/exchange.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/load.cpp b/sycl/test/atomic_ref/load.cpp index 1e0c5c2b89790..a8da04e7a790d 100644 --- a/sycl/test/atomic_ref/load.cpp +++ b/sycl/test/atomic_ref/load.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/max.cpp b/sycl/test/atomic_ref/max.cpp index 6dc4db05f968e..d783e973de77e 100644 --- a/sycl/test/atomic_ref/max.cpp +++ b/sycl/test/atomic_ref/max.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/min.cpp b/sycl/test/atomic_ref/min.cpp index 2e5f03c2ec0e4..4be8cabe9f28a 100644 --- a/sycl/test/atomic_ref/min.cpp +++ b/sycl/test/atomic_ref/min.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/store.cpp b/sycl/test/atomic_ref/store.cpp index c191794a0ef77..73ed1114aa591 100644 --- a/sycl/test/atomic_ref/store.cpp +++ b/sycl/test/atomic_ref/store.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/atomic_ref/sub.cpp b/sycl/test/atomic_ref/sub.cpp index d3ca9fe096728..cfbdd1a41b160 100644 --- a/sycl/test/atomic_ref/sub.cpp +++ b/sycl/test/atomic_ref/sub.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp b/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp index b794f6efdf158..ec3926f5d2874 100644 --- a/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp +++ b/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/basic_tests/built-ins.cpp b/sycl/test/basic_tests/built-ins.cpp index 0d45607302dd4..140facfb51a6e 100644 --- a/sycl/test/basic_tests/built-ins.cpp +++ b/sycl/test/basic_tests/built-ins.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // CUDA does not support printf. // UNSUPPORTED: cuda diff --git a/sycl/test/basic_tests/context.cpp b/sycl/test/basic_tests/context.cpp index f9e312116bdb2..3ef945415fe63 100644 --- a/sycl/test/basic_tests/context.cpp +++ b/sycl/test/basic_tests/context.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx %s -o %t.out -lsycl -I %sycl_include -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==--------------- context.cpp - SYCL context test ------------------------==// // diff --git a/sycl/test/basic_tests/device.cpp b/sycl/test/basic_tests/device.cpp index a67ee05774fda..5b88034a1e832 100644 --- a/sycl/test/basic_tests/device.cpp +++ b/sycl/test/basic_tests/device.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx %s -o %t.out -I %sycl_include -lsycl -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==--------------- device.cpp - SYCL device test --------------------------==// // diff --git a/sycl/test/basic_tests/device_selector.cpp b/sycl/test/basic_tests/device_selector.cpp index acd5c8010a369..6241b662844c3 100644 --- a/sycl/test/basic_tests/device_selector.cpp +++ b/sycl/test/basic_tests/device_selector.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_BE=%sycl_be %t.out +// RUN: %BE_RUN_PLACEHOLDER %t.out // // Checks that no device is selected when no device of desired type is // available. diff --git a/sycl/test/basic_tests/esimd/vadd.cpp b/sycl/test/basic_tests/esimd/vadd.cpp index 8de695c445254..0453a26381be7 100644 --- a/sycl/test/basic_tests/esimd/vadd.cpp +++ b/sycl/test/basic_tests/esimd/vadd.cpp @@ -1,6 +1,6 @@ // TODO ESIMD enable host device under -fsycl // RUN: %clangxx -I %sycl_include %s -o %t.out -lsycl -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include @@ -9,19 +9,19 @@ using namespace cl::sycl; class ESIMDSelector : public device_selector { - // Require GPU device unless HOST is requested in SYCL_DEVICE_TYPE env + // Require GPU device unless HOST is requested in SYCL_DEVICE_FILTER env virtual int operator()(const device &device) const { - if (const char *dev_type = getenv("SYCL_DEVICE_TYPE")) { - if (!strcmp(dev_type, "GPU")) + if (const char *dev_type = getenv("SYCL_DEVICE_FILTER")) { + if (!strcmp(dev_type, "gpu")) return device.is_gpu() ? 1000 : -1; - if (!strcmp(dev_type, "HOST")) + if (!strcmp(dev_type, "host")) return device.is_host() ? 1000 : -1; - std::cerr << "Supported 'SYCL_DEVICE_TYPE' env var values are 'GPU' and " - "'HOST', '" + std::cerr << "Supported 'SYCL_DEVICE_FILTER' env var values are 'gpu' and " + "'host', '" << dev_type << "' is not.\n"; return -1; } - // If "SYCL_DEVICE_TYPE" not defined, only allow gpu device + // If "SYCL_DEVICE_FILTER" not defined, only allow gpu device return device.is_gpu() ? 1000 : -1; } }; diff --git a/sycl/test/basic_tests/event_async_exception.cpp b/sycl/test/basic_tests/event_async_exception.cpp index 0dd803dc5d105..e94c3eb26e74a 100644 --- a/sycl/test/basic_tests/event_async_exception.cpp +++ b/sycl/test/basic_tests/event_async_exception.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==---- event_async_exception.cpp - Test for event async exceptions -------==// // diff --git a/sycl/test/basic_tests/host_image_accessor_read.cpp b/sycl/test/basic_tests/host_image_accessor_read.cpp index fa84859c136f5..3ffc3fac59f4a 100644 --- a/sycl/test/basic_tests/host_image_accessor_read.cpp +++ b/sycl/test/basic_tests/host_image_accessor_read.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==---- host_image_accessor_read.cpp - SYCL host image accessor check ----==// // diff --git a/sycl/test/basic_tests/linear-host-dev.cpp b/sycl/test/basic_tests/linear-host-dev.cpp index ff1ff837251ff..0e279d926e384 100644 --- a/sycl/test/basic_tests/linear-host-dev.cpp +++ b/sycl/test/basic_tests/linear-host-dev.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out | FileCheck %s +// RUN: %HOST_RUN_PLACEHOLDER %t.out | FileCheck %s #include #include diff --git a/sycl/test/basic_tests/parallel_for_range_host.cpp b/sycl/test/basic_tests/parallel_for_range_host.cpp index 9b79cb5ae5f88..d2cf3f0cbd1f7 100644 --- a/sycl/test/basic_tests/parallel_for_range_host.cpp +++ b/sycl/test/basic_tests/parallel_for_range_host.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/basic_tests/property_list.cpp b/sycl/test/basic_tests/property_list.cpp index e65d021502223..c42bf6b9b29ab 100644 --- a/sycl/test/basic_tests/property_list.cpp +++ b/sycl/test/basic_tests/property_list.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx %s -o %t.out -lsycl -I%sycl_include -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // // CHECK: PASSED //==--------------- property_list.cpp - SYCL property list test ------------==// diff --git a/sycl/test/basic_tests/reduction_ctor.cpp b/sycl/test/basic_tests/reduction_ctor.cpp index d160f6339ea5a..9b862e392a734 100644 --- a/sycl/test/basic_tests/reduction_ctor.cpp +++ b/sycl/test/basic_tests/reduction_ctor.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // This performs basic checks such as reduction creation, getIdentity() method, // and the combine() method of the aux class 'reducer'. diff --git a/sycl/test/bit_cast/bit_cast.cpp b/sycl/test/bit_cast/bit_cast.cpp index 5c6c1ad3504d6..849f8c5250c95 100644 --- a/sycl/test/bit_cast/bit_cast.cpp +++ b/sycl/test/bit_cast/bit_cast.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/extensions/usm.cpp b/sycl/test/extensions/usm.cpp index aa7b1f6141886..c50edbb12e6d1 100644 --- a/sycl/test/extensions/usm.cpp +++ b/sycl/test/extensions/usm.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t1.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out //==---------- allocator_equal.cpp - Allocator Equality test ---------------==// // diff --git a/sycl/test/function-pointers/fp-as-kernel-arg.cpp b/sycl/test/function-pointers/fp-as-kernel-arg.cpp index 522c4c05f6516..0ed67480f9298 100644 --- a/sycl/test/function-pointers/fp-as-kernel-arg.cpp +++ b/sycl/test/function-pointers/fp-as-kernel-arg.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -Xclang -fsycl-allow-func-ptr -std=c++14 -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // FIXME: This test should use runtime early exit once correct check for // corresponding extension is implemented diff --git a/sycl/test/function-pointers/pass-fp-through-buffer.cpp b/sycl/test/function-pointers/pass-fp-through-buffer.cpp index abb83e25dbd4c..f6215c5116da5 100644 --- a/sycl/test/function-pointers/pass-fp-through-buffer.cpp +++ b/sycl/test/function-pointers/pass-fp-through-buffer.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -Xclang -fsycl-allow-func-ptr -std=c++14 -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // FIXME: This test should use runtime early exit once correct check for // corresponding extension is implemented diff --git a/sycl/test/functor/functor_inheritance.cpp b/sycl/test/functor/functor_inheritance.cpp index 06cb3e9d81524..d7e639cbef090 100644 --- a/sycl/test/functor/functor_inheritance.cpp +++ b/sycl/test/functor/functor_inheritance.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -o %t.out %s -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/functor/kernel_functor.cpp b/sycl/test/functor/kernel_functor.cpp index bea05fcc4dcd1..18f59b122b39f 100644 --- a/sycl/test/functor/kernel_functor.cpp +++ b/sycl/test/functor/kernel_functor.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -o %t.out %s // RUN: cd %T -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==--- kernel_functor.cpp - Functors as SYCL kernel test ------------------==// // diff --git a/sycl/test/kernel_param/array-kernel-param-nested-run.cpp b/sycl/test/kernel_param/array-kernel-param-nested-run.cpp index d36da50b8fca8..86deaa64e6b9b 100755 --- a/sycl/test/kernel_param/array-kernel-param-nested-run.cpp +++ b/sycl/test/kernel_param/array-kernel-param-nested-run.cpp @@ -1,7 +1,7 @@ // This test checks kernel execution with array parameters inside structs. // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/kernel_param/array-kernel-param-run.cpp b/sycl/test/kernel_param/array-kernel-param-run.cpp index f7cc3d9391b63..0212d4503d00a 100755 --- a/sycl/test/kernel_param/array-kernel-param-run.cpp +++ b/sycl/test/kernel_param/array-kernel-param-run.cpp @@ -1,7 +1,7 @@ // This test checks kernel execution with array kernel parameters. // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/kernel_param/non-standard-layout.cpp b/sycl/test/kernel_param/non-standard-layout.cpp index 1acb9b0aac6dd..ece0afde868ae 100644 --- a/sycl/test/kernel_param/non-standard-layout.cpp +++ b/sycl/test/kernel_param/non-standard-layout.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/kernel_param/struct_kernel_param.cpp b/sycl/test/kernel_param/struct_kernel_param.cpp index 1a6490ef2342b..378369d0a5af1 100644 --- a/sycl/test/kernel_param/struct_kernel_param.cpp +++ b/sycl/test/kernel_param/struct_kernel_param.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==-struct_kernel_param.cpp-Checks passing structs as kernel params--------==// // diff --git a/sycl/test/kernel_param/union_kernel_param.cpp b/sycl/test/kernel_param/union_kernel_param.cpp index 4b0980537e4c7..fe567cc32aa74 100644 --- a/sycl/test/kernel_param/union_kernel_param.cpp +++ b/sycl/test/kernel_param/union_kernel_param.cpp @@ -1,7 +1,7 @@ // This test checks kernel execution with union type as kernel parameters. // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/lit.cfg.py b/sycl/test/lit.cfg.py index 55ed6e80d17c8..ac0cb500d5bad 100644 --- a/sycl/test/lit.cfg.py +++ b/sycl/test/lit.cfg.py @@ -75,9 +75,11 @@ llvm_config.add_tool_substitutions(['llvm-spirv'], [config.sycl_tools_dir]) -backend=lit_config.params.get('SYCL_BE', "PI_OPENCL") -lit_config.note("Backend (SYCL_BE): {}".format(backend)) -config.substitutions.append( ('%sycl_be', backend) ) +backend=lit_config.params.get('SYCL_BE', "opencl") +lit_config.note("Backend: {}".format(backend)) +config.substitutions.append( ('%sycl_be', { 'opencl': 'PI_OPENCL', 'cuda': 'PI_CUDA', 'level_zero': 'PI_LEVEL_ZERO'}[backend]) ) +config.substitutions.append( ('%BE_RUN_PLACEHOLDER', "env SYCL_DEVICE_FILTER={SYCL_BE} ".format(SYCL_BE=backend)) ) +config.substitutions.append( ('%HOST_RUN_PLACEHOLDER', "env SYCL_DEVICE_FILTER=host ") ) get_device_count_by_type_path = os.path.join(config.llvm_tools_dir, "get_device_count_by_type") @@ -131,11 +133,11 @@ def getDeviceCount(device_type): if getDeviceCount("cpu")[0]: found_at_least_one_device = True lit_config.note("Found available CPU device") - cpu_run_substitute = "env SYCL_DEVICE_TYPE=CPU SYCL_BE={SYCL_BE} ".format(SYCL_BE=backend) + cpu_run_substitute = "env SYCL_DEVICE_FILTER={SYCL_BE}:cpu ".format(SYCL_BE=backend) cpu_check_substitute = "| FileCheck %s" config.available_features.add('cpu') if platform.system() == "Linux": - cpu_run_on_linux_substitute = "env SYCL_DEVICE_TYPE=CPU SYCL_BE={SYCL_BE} ".format(SYCL_BE=backend) + cpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_BE}:cpu ".format(SYCL_BE=backend) cpu_check_on_linux_substitute = "| FileCheck %s" else: lit_config.warning("CPU device not found") @@ -157,7 +159,7 @@ def getDeviceCount(device_type): if gpu_count > 0: found_at_least_one_device = True lit_config.note("Found available GPU device") - gpu_run_substitute = " env SYCL_DEVICE_TYPE=GPU SYCL_BE={SYCL_BE} ".format(SYCL_BE=backend) + gpu_run_substitute = " env SYCL_DEVICE_FILTER={SYCL_BE}:gpu ".format(SYCL_BE=backend) gpu_check_substitute = "| FileCheck %s" config.available_features.add('gpu') if cuda: @@ -166,10 +168,10 @@ def getDeviceCount(device_type): config.available_features.add('level_zero') if platform.system() == "Linux": - gpu_run_on_linux_substitute = "env SYCL_DEVICE_TYPE=GPU SYCL_BE={SYCL_BE} ".format(SYCL_BE=backend) + gpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_BE}:gpu ".format(SYCL_BE=backend) gpu_check_on_linux_substitute = "| FileCheck %s" # ESIMD-specific setup. Requires OpenCL for now. - esimd_run_substitute = " env SYCL_BE=PI_OPENCL SYCL_DEVICE_TYPE=GPU SYCL_PROGRAM_COMPILE_OPTIONS=-vc-codegen" + esimd_run_substitute = " env SYCL_DEVICE_FILTER=opencl:gpu SYCL_PROGRAM_COMPILE_OPTIONS=-vc-codegen" config.substitutions.append( ('%ESIMD_RUN_PLACEHOLDER', esimd_run_substitute) ) config.substitutions.append( ('%clangxx-esimd', "clang++ -fsycl-explicit-simd" ) ) else: @@ -185,7 +187,7 @@ def getDeviceCount(device_type): if getDeviceCount("accelerator")[0]: found_at_least_one_device = True lit_config.note("Found available accelerator device") - acc_run_substitute = " env SYCL_DEVICE_TYPE=ACC " + acc_run_substitute = " env SYCL_DEVICE_FILTER={SYCL_BE}:acc ".format(SYCL_BE=backend) acc_check_substitute = "| FileCheck %s" config.available_features.add('accelerator') else: diff --git a/sycl/test/multi_ptr/multi_ptr.cpp b/sycl/test/multi_ptr/multi_ptr.cpp index dea8dd3ee22a4..50a1d88c495ab 100644 --- a/sycl/test/multi_ptr/multi_ptr.cpp +++ b/sycl/test/multi_ptr/multi_ptr.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -fsycl-dead-args-optimization %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %clangxx -DRESTRICT_WRITE_ACCESS_TO_CONSTANT_PTR -fsycl -fsycl-targets=%sycl_triple -fsycl-dead-args-optimization %s -o %t1.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out //==--------------- multi_ptr.cpp - SYCL multi_ptr test --------------------==// // diff --git a/sycl/test/multisource/multisource.cpp b/sycl/test/multisource/multisource.cpp index 0797b37ab4e05..966b09fbdc504 100644 --- a/sycl/test/multisource/multisource.cpp +++ b/sycl/test/multisource/multisource.cpp @@ -10,14 +10,14 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.kernel.o %s -DINIT_KERNEL -DCALC_KERNEL // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.main.o %s -DMAIN_APP // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %t.kernel.o %t.main.o -o %t.fat -// RUN: env SYCL_DEVICE_TYPE=HOST %t.fat +// RUN: %HOST_RUN_PLACEHOLDER %t.fat // Multiple sources with kernel code // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.init.o %s -DINIT_KERNEL // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.calc.o %s -DCALC_KERNEL // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.main.o %s -DMAIN_APP // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %t.init.o %t.calc.o %t.main.o -o %t.fat -// RUN: env SYCL_DEVICE_TYPE=HOST %t.fat +// RUN: %HOST_RUN_PLACEHOLDER %t.fat #include diff --git a/sycl/test/on-device/basic_tests/access_to_subset.cpp b/sycl/test/on-device/basic_tests/access_to_subset.cpp index ecbcaf2984416..b0a80f8567cb6 100644 --- a/sycl/test/on-device/basic_tests/access_to_subset.cpp +++ b/sycl/test/on-device/basic_tests/access_to_subset.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/boolean.cpp b/sycl/test/on-device/basic_tests/boolean.cpp index 031a0afafda01..cd2b7388cc314 100644 --- a/sycl/test/on-device/basic_tests/boolean.cpp +++ b/sycl/test/on-device/basic_tests/boolean.cpp @@ -3,7 +3,7 @@ // XFAIL: gpu && (level_zero || opencl) // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer.cpp b/sycl/test/on-device/basic_tests/buffer/buffer.cpp index 6bc8a4c21de8d..96a2102ccfbd2 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t2.out +// RUN: %HOST_RUN_PLACEHOLDER %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp b/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp index b2e5efa2f43fd..84bb92312d1fe 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -std=c++17 -o %t1.out -lsycl -I %sycl_include -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %clangxx -std=c++17 -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t2.out +// RUN: %HOST_RUN_PLACEHOLDER %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp b/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp index c84a06bbbace4..9feca8f4b2f39 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp b/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp index 4c32a8b2c6b1e..3d204bce5fd23 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t2.out +// RUN: %HOST_RUN_PLACEHOLDER %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp b/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp index c614c76cb03c6..39a43bb7f3c51 100644 --- a/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp +++ b/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/device_equality.cpp b/sycl/test/on-device/basic_tests/device_equality.cpp index 9b027c4c11681..24b27c63db078 100644 --- a/sycl/test/on-device/basic_tests/device_equality.cpp +++ b/sycl/test/on-device/basic_tests/device_equality.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t1.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %CPU_RUN_PLACEHOLDER %t1.out // RUN: %GPU_RUN_PLACEHOLDER %t1.out diff --git a/sycl/test/on-device/basic_tests/device_event.cpp b/sycl/test/on-device/basic_tests/device_event.cpp index 79231031d8e50..016794df59652 100644 --- a/sycl/test/on-device/basic_tests/device_event.cpp +++ b/sycl/test/on-device/basic_tests/device_event.cpp @@ -2,7 +2,7 @@ // RUN: %GPU_RUN_PLACEHOLDER %t.run // RUN: %CPU_RUN_PLACEHOLDER %t.run // RUN: %ACC_RUN_PLACEHOLDER %t.run -// RUNx (TODO: nd_item::barrier() is not implemented on HOST): env SYCL_DEVICE_TYPE=HOST %t.run +// RUNx (TODO: nd_item::barrier() is not implemented on HOST): %HOST_RUN_PLACEHOLDER %t.run //==--------device_event.cpp - SYCL class device_event test ----------------==// // diff --git a/sycl/test/on-device/basic_tests/diagnostics/handler.cpp b/sycl/test/on-device/basic_tests/diagnostics/handler.cpp index 8f3406893d057..8143a621eb91c 100644 --- a/sycl/test/on-device/basic_tests/diagnostics/handler.cpp +++ b/sycl/test/on-device/basic_tests/diagnostics/handler.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_BE=%sycl_be %t.out | FileCheck %s +// RUN: %BE_RUN_PLACEHOLDER %t.out | FileCheck %s //==------------------- handler.cpp ----------------------------------------==// // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. diff --git a/sycl/test/on-device/basic_tests/event.cpp b/sycl/test/on-device/basic_tests/event.cpp index df315e59b6415..1d365a596cc68 100644 --- a/sycl/test/on-device/basic_tests/event.cpp +++ b/sycl/test/on-device/basic_tests/event.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/event_creation.cpp b/sycl/test/on-device/basic_tests/event_creation.cpp index edb8b27d6c8d6..33f3e551b9063 100644 --- a/sycl/test/on-device/basic_tests/event_creation.cpp +++ b/sycl/test/on-device/basic_tests/event_creation.cpp @@ -1,7 +1,7 @@ // REQUIRES: opencl // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -L %opencl_libs_dir -lOpenCL -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/event_profiling_info.cpp b/sycl/test/on-device/basic_tests/event_profiling_info.cpp index 0a71ebac93c2d..df8fb9f6af9e9 100644 --- a/sycl/test/on-device/basic_tests/event_profiling_info.cpp +++ b/sycl/test/on-device/basic_tests/event_profiling_info.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out // -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/get_backend.cpp b/sycl/test/on-device/basic_tests/get_backend.cpp index a312304e0741b..2dab19cfd9866 100644 --- a/sycl/test/on-device/basic_tests/get_backend.cpp +++ b/sycl/test/on-device/basic_tests/get_backend.cpp @@ -3,7 +3,8 @@ // //==----------------- get_backend.cpp ------------------------==// // This is a test of get_backend(). -// Do not set SYCL_BE. We do not want the preferred backend. +// Do not set SYCL_DEVICE_FILTER. We do not want the preferred +// backend. //==----------------------------------------------------------==// #include diff --git a/sycl/test/on-device/basic_tests/get_nonhost_devices.cpp b/sycl/test/on-device/basic_tests/get_nonhost_devices.cpp index 536dcafb5ac76..20fe65455435e 100644 --- a/sycl/test/on-device/basic_tests/get_nonhost_devices.cpp +++ b/sycl/test/on-device/basic_tests/get_nonhost_devices.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_BE=%sycl_be %t.out +// RUN: %BE_RUN_PLACEHOLDER %t.out // // Check that the host device is not included in devices returned by // get_devices() if a non-host device type is specified. diff --git a/sycl/test/on-device/basic_tests/half_type.cpp b/sycl/test/on-device/basic_tests/half_type.cpp index dfff5037cdbf1..bc2f768cd083e 100644 --- a/sycl/test/on-device/basic_tests/half_type.cpp +++ b/sycl/test/on-device/basic_tests/half_type.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/host_always_works.cpp b/sycl/test/on-device/basic_tests/host_always_works.cpp index 4b79b3211f43f..e2cfbc08c7a7f 100644 --- a/sycl/test/on-device/basic_tests/host_always_works.cpp +++ b/sycl/test/on-device/basic_tests/host_always_works.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t1.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %CPU_RUN_PLACEHOLDER %t1.out // RUN: %GPU_RUN_PLACEHOLDER %t1.out // RUN: %ACC_RUN_PLACEHOLDER %t1.out diff --git a/sycl/test/on-device/basic_tests/host_platform_avail.cpp b/sycl/test/on-device/basic_tests/host_platform_avail.cpp index 3364137fa6332..e4097d40f7bc7 100644 --- a/sycl/test/on-device/basic_tests/host_platform_avail.cpp +++ b/sycl/test/on-device/basic_tests/host_platform_avail.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t1.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %CPU_RUN_PLACEHOLDER %t1.out // RUN: %GPU_RUN_PLACEHOLDER %t1.out // RUN: %ACC_RUN_PLACEHOLDER %t1.out diff --git a/sycl/test/on-device/basic_tests/image.cpp b/sycl/test/on-device/basic_tests/image.cpp index e20096f4d0229..02f052003a2a9 100644 --- a/sycl/test/on-device/basic_tests/image.cpp +++ b/sycl/test/on-device/basic_tests/image.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_read.cpp b/sycl/test/on-device/basic_tests/image/image_read.cpp index d9c5cc36d5e79..d4368c589273a 100644 --- a/sycl/test/on-device/basic_tests/image/image_read.cpp +++ b/sycl/test/on-device/basic_tests/image/image_read.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp b/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp index 4b9685617dbea..7ecf548d442d8 100644 --- a/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp +++ b/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_write.cpp b/sycl/test/on-device/basic_tests/image/image_write.cpp index 79959d368f5f6..ef9a7fd6246af 100644 --- a/sycl/test/on-device/basic_tests/image/image_write.cpp +++ b/sycl/test/on-device/basic_tests/image/image_write.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp b/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp index 11fc418425991..d0f52b370bed7 100644 --- a/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp +++ b/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp b/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp index 847a4b83e6c9a..925a767f606e9 100644 --- a/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp +++ b/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // diff --git a/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp b/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp index 4fc035daea42a..519e6b10eaa1f 100644 --- a/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp +++ b/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp b/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp index 72cda15bf4647..ff88d3bbc79e0 100644 --- a/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp +++ b/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_array.cpp b/sycl/test/on-device/basic_tests/image_array.cpp index 478f5412ffdc0..3f93d51c2d282 100644 --- a/sycl/test/on-device/basic_tests/image_array.cpp +++ b/sycl/test/on-device/basic_tests/image_array.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUNx: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_constructors.cpp b/sycl/test/on-device/basic_tests/image_constructors.cpp index 8891393f9f1fe..f9759bb744f7d 100644 --- a/sycl/test/on-device/basic_tests/image_constructors.cpp +++ b/sycl/test/on-device/basic_tests/image_constructors.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t2.out +// RUN: %HOST_RUN_PLACEHOLDER %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/info.cpp b/sycl/test/on-device/basic_tests/info.cpp index 9b4d4d7cc2031..ddcd420f813ff 100644 --- a/sycl/test/on-device/basic_tests/info.cpp +++ b/sycl/test/on-device/basic_tests/info.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/info_ocl_version.cpp b/sycl/test/on-device/basic_tests/info_ocl_version.cpp index e42383bbe3e79..46ea03fb33c9e 100644 --- a/sycl/test/on-device/basic_tests/info_ocl_version.cpp +++ b/sycl/test/on-device/basic_tests/info_ocl_version.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: env %CPU_RUN_PLACEHOLDER %t.out // RUN: env %GPU_RUN_PLACEHOLDER %t.out // RUN: env %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp b/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp index a4ec46b42bc9a..e4b58dedbb608 100644 --- a/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp +++ b/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -Wno-sycl-strict -Xclang -verify-ignore-unexpected=note,warning -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.out +// RUN: %HOST_RUN_PLACEHOLDER %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t2.out +// RUN: %HOST_RUN_PLACEHOLDER %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/scalar_vec_access.cpp b/sycl/test/on-device/basic_tests/scalar_vec_access.cpp index e163ae0aa22c6..4e2277448e1c0 100644 --- a/sycl/test/on-device/basic_tests/scalar_vec_access.cpp +++ b/sycl/test/on-device/basic_tests/scalar_vec_access.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out | FileCheck %s +// RUN: %HOST_RUN_PLACEHOLDER %t.out | FileCheck %s // RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER // RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER // RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER diff --git a/sycl/test/on-device/basic_tests/stream/stream.cpp b/sycl/test/on-device/basic_tests/stream/stream.cpp index 5e5110a8ee355..9451d575db394 100644 --- a/sycl/test/on-device/basic_tests/stream/stream.cpp +++ b/sycl/test/on-device/basic_tests/stream/stream.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out | FileCheck %s +// RUN: %HOST_RUN_PLACEHOLDER %t.out | FileCheck %s // RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER // RUN: %GPU_RUN_ON_LINUX_PLACEHOLDER %t.out %GPU_CHECK_ON_LINUX_PLACEHOLDER // RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER diff --git a/sycl/test/on-device/basic_tests/subdevice.cpp b/sycl/test/on-device/basic_tests/subdevice.cpp index bd4e237f80347..fca3abd7f998d 100644 --- a/sycl/test/on-device/basic_tests/subdevice.cpp +++ b/sycl/test/on-device/basic_tests/subdevice.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/swizzle_op.cpp b/sycl/test/on-device/basic_tests/swizzle_op.cpp index 49b997bb38c9f..abfcee0303ef3 100644 --- a/sycl/test/on-device/basic_tests/swizzle_op.cpp +++ b/sycl/test/on-device/basic_tests/swizzle_op.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/sycl-namespace.cpp b/sycl/test/on-device/basic_tests/sycl-namespace.cpp index 64832e14b2665..3304bb4464604 100644 --- a/sycl/test/on-device/basic_tests/sycl-namespace.cpp +++ b/sycl/test/on-device/basic_tests/sycl-namespace.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/unused_pointer.cpp b/sycl/test/on-device/basic_tests/unused_pointer.cpp index a1c5dbb269347..8583943a916b0 100644 --- a/sycl/test/on-device/basic_tests/unused_pointer.cpp +++ b/sycl/test/on-device/basic_tests/unused_pointer.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/config/select_device.cpp b/sycl/test/on-device/config/select_device.cpp index 49407f4d6f0dd..d032c52e10fac 100644 --- a/sycl/test/on-device/config/select_device.cpp +++ b/sycl/test/on-device/config/select_device.cpp @@ -173,9 +173,9 @@ static std::vector getAllowListDesc(std::string allowList) { int main() { bool passed = false; - std::string sycl_be("PI_OPENCL"); - if (getenv("SYCL_BE")) { - sycl_be = getenv("SYCL_BE"); + std::string sycl_be("opencl"); + if (getenv("SYCL_DEVICE_FILTER")) { + sycl_be = getenv("SYCL_DEVICE_FILTER"); } // Test the GPU devices name and version number. @@ -191,13 +191,13 @@ int main() { addEscapeSymbolToSpecialCharacters(name); std::string ver = dev.get_info(); if ((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) { + (sycl_be.find("opencl") != std::string::npos)) { fs << "DeviceName:{{" << name << "}},DriverVersion:{{" << ver << "}}" << std::endl; passed = true; break; } else if ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos)) { + (sycl_be.find("level_zero") != std::string::npos)) { fs << "DeviceName:{{" << name << "}},DriverVersion:{{" << ver << "}}" << std::endl; passed = true; @@ -251,9 +251,9 @@ int main() { addEscapeSymbolToSpecialCharacters(name); std::string ver = plt.get_info(); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "PlatformName:{{" << name << "}},PlatformVersion:{{" << ver << "}}" << std::endl; passed = true; @@ -307,9 +307,9 @@ int main() { addEscapeSymbolToSpecialCharacters(name); std::string ver("98.76.54321"); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "DeviceName:{{" << name << "}},DriverVersion:{{" << ver << "}}" << std::endl; passed = true; @@ -361,14 +361,14 @@ int main() { std::string name = plt.get_info(); addEscapeSymbolToSpecialCharacters(name); if ((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) { + (sycl_be.find("opencl") != std::string::npos)) { std::string ver("OpenCL 12.34"); fs << "PlatformName:{{" << name << "}},PlatformVersion:{{" << ver << "}}" << std::endl; passed = true; break; } else if ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos)) { + (sycl_be.find("level_zero") != std::string::npos)) { std::string ver("12.34"); fs << "PlatformName:{{" << name << "}},PlatformVersion:{{" << ver << "}}" << std::endl; @@ -432,9 +432,9 @@ int main() { } ver.replace(start, pos - start, "*"); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "DeviceName:{{" << name << "}},DriverVersion:{{" << ver << "}}" << std::endl; passed = true; @@ -489,9 +489,9 @@ int main() { std::string name = dev.get_info(); addEscapeSymbolToSpecialCharacters(name); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "DeviceName:{{" << name << "}}" << std::endl; passed = true; break; @@ -538,9 +538,9 @@ int main() { std::string name = plt.get_info(); addEscapeSymbolToSpecialCharacters(name); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "PlatformName:{{" << name << "}}" << std::endl; passed = true; break; @@ -591,9 +591,9 @@ int main() { addEscapeSymbolToSpecialCharacters(name); std::string ver = dev.get_info(); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { if (count > 0) { ss << " | "; } @@ -653,9 +653,9 @@ int main() { std::string name = dev.get_info(); addEscapeSymbolToSpecialCharacters(name); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "DeviceName:HAHA{{" << name << "}}" << std::endl; passed = true; break; @@ -706,9 +706,9 @@ int main() { std::string name = plt.get_info(); addEscapeSymbolToSpecialCharacters(name); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "PlatformName:HAHA{{" << name << "}}" << std::endl; passed = true; break; @@ -760,9 +760,9 @@ int main() { addEscapeSymbolToSpecialCharacters(name); std::string ver = dev.get_info(); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "DeviceName:{{" << name << "}},DriverVersion:HAHA{{" << ver << "}}" << std::endl; passed = true; @@ -815,9 +815,9 @@ int main() { addEscapeSymbolToSpecialCharacters(name); std::string ver = plt.get_info(); if (((plt.get_backend() == backend::opencl) && - (sycl_be.find("OPENCL") != std::string::npos)) || + (sycl_be.find("opencl") != std::string::npos)) || ((plt.get_backend() == backend::level_zero) && - (sycl_be.find("LEVEL_ZERO") != std::string::npos))) { + (sycl_be.find("level_zero") != std::string::npos))) { fs << "PlatformName:{{" << name << "}},PlatformVersion:HAHA{{" << ver << "}}" << std::endl; passed = true; diff --git a/sycl/test/on-device/dot_product/dot_product_int_test.cpp b/sycl/test/on-device/dot_product/dot_product_int_test.cpp index e68d321446426..c6eaec1002bff 100755 --- a/sycl/test/on-device/dot_product/dot_product_int_test.cpp +++ b/sycl/test/on-device/dot_product/dot_product_int_test.cpp @@ -2,7 +2,7 @@ // For now we only check fallback support because DG1 hardware is not widespread // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/dot_product/dot_product_vec_test.cpp b/sycl/test/on-device/dot_product/dot_product_vec_test.cpp index e6277b17f2d62..37570df1783c6 100644 --- a/sycl/test/on-device/dot_product/dot_product_vec_test.cpp +++ b/sycl/test/on-device/dot_product/dot_product_vec_test.cpp @@ -2,7 +2,7 @@ // For now we only check fallback support because DG1 hardware is not widespread // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/hier_par/hier_par_basic.cpp b/sycl/test/on-device/hier_par/hier_par_basic.cpp index 5670663e2e149..9b2fbd4be6808 100644 --- a/sycl/test/on-device/hier_par/hier_par_basic.cpp +++ b/sycl/test/on-device/hier_par/hier_par_basic.cpp @@ -7,7 +7,7 @@ //===----------------------------------------------------------------------===// // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/hier_par/hier_par_wgscope.cpp b/sycl/test/on-device/hier_par/hier_par_wgscope.cpp index 5dfbb61a187bd..4a758f4925788 100644 --- a/sycl/test/on-device/hier_par/hier_par_wgscope.cpp +++ b/sycl/test/on-device/hier_par/hier_par_wgscope.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp b/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp index 1041199f8c11f..46de7bd825803 100644 --- a/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp +++ b/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp @@ -8,7 +8,7 @@ // RUN: %clangxx -O0 -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/plugins/interop-opencl.cpp b/sycl/test/on-device/plugins/interop-opencl.cpp index d46cd5ac315d5..e0d41a933b1bc 100644 --- a/sycl/test/on-device/plugins/interop-opencl.cpp +++ b/sycl/test/on-device/plugins/interop-opencl.cpp @@ -1,9 +1,9 @@ // REQUIRES: opencl // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -I %sycl_source_dir %s -o %t.out -// RUN: env SYCL_BE=PI_OPENCL %CPU_RUN_PLACEHOLDER %t.out -// RUN: env SYCL_BE=PI_OPENCL %GPU_RUN_PLACEHOLDER %t.out -// RUN: env SYCL_BE=PI_OPENCL %ACC_RUN_PLACEHOLDER %t.out +// RUN: %CPU_RUN_PLACEHOLDER %t.out +// RUN: %GPU_RUN_PLACEHOLDER %t.out +// RUN: %ACC_RUN_PLACEHOLDER %t.out //==-- interop-opencl.cpp - SYCL test for OpenCL interop API --------------===// // diff --git a/sycl/test/on-device/plugins/sycl-ls-gpu-cuda.cpp b/sycl/test/on-device/plugins/sycl-ls-gpu-cuda.cpp index 8a2a9aca5b2c0..a1ed5449d560d 100755 --- a/sycl/test/on-device/plugins/sycl-ls-gpu-cuda.cpp +++ b/sycl/test/on-device/plugins/sycl-ls-gpu-cuda.cpp @@ -1,6 +1,6 @@ // REQUIRES: gpu, cuda -// RUN: env SYCL_BE=PI_CUDA sycl-ls --verbose >%t.cuda.out +// RUN: %BE_RUN_PLACEHOLDER sycl-ls --verbose >%t.cuda.out // RUN: FileCheck %s --check-prefixes=CHECK-BUILTIN-GPU-CUDA,CHECK-CUSTOM-GPU-CUDA --input-file %t.cuda.out // CHECK-BUILTIN-GPU-CUDA: gpu_selector(){{.*}}GPU :{{.*}}CUDA diff --git a/sycl/test/on-device/plugins/sycl-ls-gpu-default.cpp b/sycl/test/on-device/plugins/sycl-ls-gpu-default.cpp index 11165b63197d2..a7f65df00689d 100644 --- a/sycl/test/on-device/plugins/sycl-ls-gpu-default.cpp +++ b/sycl/test/on-device/plugins/sycl-ls-gpu-default.cpp @@ -1,6 +1,6 @@ // REQUIRES: gpu -// RUN: env --unset=SYCL_BE sycl-ls --verbose >%t.default.out +// RUN: env --unset=SYCL_DEVICE_FILTER sycl-ls --verbose >%t.default.out // RUN: FileCheck %s --check-prefixes=CHECK-GPU-BUILTIN,CHECK-GPU-CUSTOM --input-file %t.default.out // CHECK-GPU-BUILTIN: gpu_selector(){{.*}}GPU : {{.*}}Level-Zero diff --git a/sycl/test/on-device/plugins/sycl-ls-gpu-opencl.cpp b/sycl/test/on-device/plugins/sycl-ls-gpu-opencl.cpp index 23dec78cdd101..148118e4dc81e 100644 --- a/sycl/test/on-device/plugins/sycl-ls-gpu-opencl.cpp +++ b/sycl/test/on-device/plugins/sycl-ls-gpu-opencl.cpp @@ -1,6 +1,6 @@ // REQUIRES: gpu, opencl -// RUN: env SYCL_BE=PI_OPENCL sycl-ls --verbose >%t.opencl.out +// RUN: %BE_RUN_PLACEHOLDER sycl-ls --verbose >%t.opencl.out // RUN: FileCheck %s --check-prefixes=CHECK-GPU-BUILTIN,CHECK-GPU-CUSTOM --input-file %t.opencl.out // CHECK-GPU-BUILTIN: gpu_selector(){{.*}}GPU : {{.*}}OpenCL diff --git a/sycl/test/on-device/plugins/sycl-ls-gpu-sycl-be.cpp b/sycl/test/on-device/plugins/sycl-ls-gpu-sycl-be.cpp index 02d217941de24..ad8e673682da5 100755 --- a/sycl/test/on-device/plugins/sycl-ls-gpu-sycl-be.cpp +++ b/sycl/test/on-device/plugins/sycl-ls-gpu-sycl-be.cpp @@ -3,13 +3,13 @@ // RUN: sycl-ls --verbose >%t.default.out // RUN: FileCheck %s --check-prefixes=CHECK-BUILTIN-GPU-OPENCL,CHECK-CUSTOM-GPU-OPENCL --input-file %t.default.out -// RUN: env SYCL_BE=PI_OPENCL sycl-ls --verbose >%t.opencl.out +// RUN: env SYCL_DEVICE_FILTER=opencl sycl-ls --verbose >%t.opencl.out // RUN: FileCheck %s --check-prefixes=CHECK-BUILTIN-GPU-OPENCL,CHECK-CUSTOM-GPU-OPENCL --input-file %t.opencl.out // CHECK-BUILTIN-GPU-OPENCL: gpu_selector(){{.*}}GPU : OpenCL // CHECK-CUSTOM-GPU-OPENCL: custom_selector(gpu){{.*}}GPU : OpenCL -// RUN: env SYCL_BE=PI_CUDA sycl-ls --verbose >%t.cuda.out +// RUN: env SYCL_DEVICE_FILTER=cuda sycl-ls --verbose >%t.cuda.out // RUN: FileCheck %s --check-prefixes=CHECK-BUILTIN-GPU-CUDA,CHECK-CUSTOM-GPU-CUDA --input-file %t.cuda.out // CHECK-BUILTIN-GPU-CUDA: gpu_selector(){{.*}}GPU : CUDA diff --git a/sycl/test/on-device/plugins/sycl-targets-order.cpp b/sycl/test/on-device/plugins/sycl-targets-order.cpp index d94ef572eff56..8143c677066d2 100644 --- a/sycl/test/on-device/plugins/sycl-targets-order.cpp +++ b/sycl/test/on-device/plugins/sycl-targets-order.cpp @@ -1,9 +1,9 @@ // RUN: %clangxx -fsycl -fsycl-targets=spir64-unknown-unknown-sycldevice,nvptx64-unknown-unknown-sycldevice %s -o %t-spir64-nvptx64.out -// RUN: env SYCL_BE=PI_OPENCL %t-spir64-nvptx64.out -// RUN: env SYCL_BE=PI_CUDA %t-spir64-nvptx64.out +// RUN: env SYCL_DEVICE_FILTER=opencl %t-spir64-nvptx64.out +// RUN: env SYCL_DEVICE_FILTER=cuda %t-spir64-nvptx64.out // RUN: %clangxx -fsycl -fsycl-targets=nvptx64-unknown-unknown-sycldevice,spir64-unknown-unknown-sycldevice %s -o %t-nvptx64-spir64.out -// RUN: env SYCL_BE=PI_OPENCL %t-nvptx64-spir64.out -// RUN: env SYCL_BE=PI_CUDA %t-nvptx64-spir64.out +// RUN: env SYCL_DEVICE_FILTER=opencl %t-nvptx64-spir64.out +// RUN: env SYCL_DEVICE_FILTER=cuda %t-nvptx64-spir64.out // REQUIRES: opencl, cuda diff --git a/sycl/test/on-device/reduction/reduction_nd_conditional.cpp b/sycl/test/on-device/reduction/reduction_nd_conditional.cpp index d8c6d56078064..01107b8bc49a7 100644 --- a/sycl/test/on-device/reduction/reduction_nd_conditional.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_conditional.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp b/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp index c45f5254661ad..51ab97028c398 100644 --- a/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp @@ -4,7 +4,7 @@ // RUN: %ACC_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports intel::reduce() and barrier() -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // This test performs basic checks of parallel_for(nd_range, reduction, func) // used with 'double' type. diff --git a/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp b/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp index 47d1474910219..c23dfa5969329 100644 --- a/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp @@ -6,7 +6,7 @@ // RUNx: %ACC_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports intel::reduce() and barrier() -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // This test performs basic checks of parallel_for(nd_range, reduction, func) // used with 'half' type. diff --git a/sycl/test/on-device/reduction/reduction_nd_lambda.cpp b/sycl/test/on-device/reduction/reduction_nd_lambda.cpp index 26bb6c9fb3571..dee12272f75e2 100644 --- a/sycl/test/on-device/reduction/reduction_nd_lambda.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_lambda.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp b/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp index 1853822bea5eb..063d299a3a0cc 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp b/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp index a71634371cd87..5fc7cf39e7a33 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp b/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp index f5728345f0cc0..fc42adc050632 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp b/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp index bfc2c85d171d9..9748c3569b928 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_placeholder.cpp b/sycl/test/on-device/reduction/reduction_placeholder.cpp index 4187fc52fbaf3..231fd2c387891 100644 --- a/sycl/test/on-device/reduction/reduction_placeholder.cpp +++ b/sycl/test/on-device/reduction/reduction_placeholder.cpp @@ -3,7 +3,7 @@ // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp b/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp index 415e87dd506c0..e62a10af2b468 100644 --- a/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp +++ b/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp @@ -3,7 +3,7 @@ // RUN: %ACC_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/reduction/reduction_transparent.cpp b/sycl/test/on-device/reduction/reduction_transparent.cpp index 40cf1e4826ea9..6c421bf6ae0e2 100644 --- a/sycl/test/on-device/reduction/reduction_transparent.cpp +++ b/sycl/test/on-device/reduction/reduction_transparent.cpp @@ -3,7 +3,7 @@ // RUN: %ACC_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/reduction/reduction_usm.cpp b/sycl/test/on-device/reduction/reduction_usm.cpp index 4bf249f8d53c1..be32eca07c763 100644 --- a/sycl/test/on-device/reduction/reduction_usm.cpp +++ b/sycl/test/on-device/reduction/reduction_usm.cpp @@ -3,7 +3,7 @@ // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out -// RUNx: env SYCL_DEVICE_TYPE=HOST %t.out +// RUNx: %HOST_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/regression/usm_malloc_shared.cpp b/sycl/test/on-device/regression/usm_malloc_shared.cpp index c078d225791f8..35122c1a905a3 100644 --- a/sycl/test/on-device/regression/usm_malloc_shared.cpp +++ b/sycl/test/on-device/regression/usm_malloc_shared.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // This test checks if users will successfully allocate 160, 0, and -16 bytes of diff --git a/sycl/test/on-device/spec_const/spec_const_hw.cpp b/sycl/test/on-device/spec_const/spec_const_hw.cpp index bbb579b74a0ad..0a8d446ece193 100644 --- a/sycl/test/on-device/spec_const/spec_const_hw.cpp +++ b/sycl/test/on-device/spec_const/spec_const_hw.cpp @@ -1,7 +1,7 @@ // UNSUPPORTED: cuda // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // diff --git a/sycl/test/on-device/spec_const/spec_const_neg.cpp b/sycl/test/on-device/spec_const/spec_const_neg.cpp index d08b77b884378..a0f34d19634f7 100644 --- a/sycl/test/on-device/spec_const/spec_const_neg.cpp +++ b/sycl/test/on-device/spec_const/spec_const_neg.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // Specialization constants are not supported on FPGA h/w and emulator. diff --git a/sycl/test/on-device/spec_const/spec_const_redefine.cpp b/sycl/test/on-device/spec_const/spec_const_redefine.cpp index 8621d58504d09..477e8a40017e0 100644 --- a/sycl/test/on-device/spec_const/spec_const_redefine.cpp +++ b/sycl/test/on-device/spec_const/spec_const_redefine.cpp @@ -1,7 +1,7 @@ // UNSUPPORTED: cuda // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER // RUN: env SYCL_PI_TRACE=2 %GPU_RUN_PLACEHOLDER %t.out 2>&1 %GPU_CHECK_PLACEHOLDER // diff --git a/sycl/test/on-device/sub_group/attributes.cpp b/sycl/test/on-device/sub_group/attributes.cpp index df39459e49d57..19edacb7a6a5d 100644 --- a/sycl/test/on-device/sub_group/attributes.cpp +++ b/sycl/test/on-device/sub_group/attributes.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUNx: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/barrier.cpp b/sycl/test/on-device/sub_group/barrier.cpp index aca849411b12a..5843c56836785 100644 --- a/sycl/test/on-device/sub_group/barrier.cpp +++ b/sycl/test/on-device/sub_group/barrier.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/broadcast.cpp b/sycl/test/on-device/sub_group/broadcast.cpp index f49d35c531b64..9231a44dcc9c9 100644 --- a/sycl/test/on-device/sub_group/broadcast.cpp +++ b/sycl/test/on-device/sub_group/broadcast.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/broadcast_fp64.cpp b/sycl/test/on-device/sub_group/broadcast_fp64.cpp index e4b3eb09cc7b2..6ab60cac65262 100644 --- a/sycl/test/on-device/sub_group/broadcast_fp64.cpp +++ b/sycl/test/on-device/sub_group/broadcast_fp64.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/common.cpp b/sycl/test/on-device/sub_group/common.cpp index 3bbdc9832fe82..07e3ab5387cb7 100644 --- a/sycl/test/on-device/sub_group/common.cpp +++ b/sycl/test/on-device/sub_group/common.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/generic-shuffle.cpp b/sycl/test/on-device/sub_group/generic-shuffle.cpp index c9ece6143be97..5017ad0a2b108 100644 --- a/sycl/test/on-device/sub_group/generic-shuffle.cpp +++ b/sycl/test/on-device/sub_group/generic-shuffle.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/generic_reduce.cpp b/sycl/test/on-device/sub_group/generic_reduce.cpp index 40f2901ff3bfb..3018f63598052 100644 --- a/sycl/test/on-device/sub_group/generic_reduce.cpp +++ b/sycl/test/on-device/sub_group/generic_reduce.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -std=c++14 %s -o %t.out // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple -std=c++14 -D SG_GPU %s -o %t_gpu.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t_gpu.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/info.cpp b/sycl/test/on-device/sub_group/info.cpp index 83cd72e431efc..d8602b319ac33 100644 --- a/sycl/test/on-device/sub_group/info.cpp +++ b/sycl/test/on-device/sub_group/info.cpp @@ -1,7 +1,7 @@ // REQUIRES: opencl // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/load_store.cpp b/sycl/test/on-device/sub_group/load_store.cpp index 0a614db1849c5..8706ea92be021 100644 --- a/sycl/test/on-device/sub_group/load_store.cpp +++ b/sycl/test/on-device/sub_group/load_store.cpp @@ -6,7 +6,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/reduce.cpp b/sycl/test/on-device/sub_group/reduce.cpp index af63417b75648..ecb95c4a3185d 100644 --- a/sycl/test/on-device/sub_group/reduce.cpp +++ b/sycl/test/on-device/sub_group/reduce.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/reduce_fp64.cpp b/sycl/test/on-device/sub_group/reduce_fp64.cpp index 98102bb0de0bd..32bd0964b6ad3 100644 --- a/sycl/test/on-device/sub_group/reduce_fp64.cpp +++ b/sycl/test/on-device/sub_group/reduce_fp64.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/scan.cpp b/sycl/test/on-device/sub_group/scan.cpp index 00520a7bb8c3b..1c6ec39c8db56 100644 --- a/sycl/test/on-device/sub_group/scan.cpp +++ b/sycl/test/on-device/sub_group/scan.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/scan_fp64.cpp b/sycl/test/on-device/sub_group/scan_fp64.cpp index 0ba135c67e4a8..8e51f5c6c8642 100644 --- a/sycl/test/on-device/sub_group/scan_fp64.cpp +++ b/sycl/test/on-device/sub_group/scan_fp64.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/shuffle.cpp b/sycl/test/on-device/sub_group/shuffle.cpp index 6d551a92bde7d..13d71be0edce1 100644 --- a/sycl/test/on-device/sub_group/shuffle.cpp +++ b/sycl/test/on-device/sub_group/shuffle.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/shuffle_fp64.cpp b/sycl/test/on-device/sub_group/shuffle_fp64.cpp index a1b153b4b8e36..b0191d910ef38 100644 --- a/sycl/test/on-device/sub_group/shuffle_fp64.cpp +++ b/sycl/test/on-device/sub_group/shuffle_fp64.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/vote.cpp b/sycl/test/on-device/sub_group/vote.cpp index 74ae90a0f4717..df16d59db4c6d 100644 --- a/sycl/test/on-device/sub_group/vote.cpp +++ b/sycl/test/on-device/sub_group/vote.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/regression/atomic_load.cpp b/sycl/test/regression/atomic_load.cpp index bff99f2c49a60..153ea8c72c717 100644 --- a/sycl/test/regression/atomic_load.cpp +++ b/sycl/test/regression/atomic_load.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include using namespace cl::sycl; diff --git a/sycl/test/regression/builtins_vector1.cpp b/sycl/test/regression/builtins_vector1.cpp index 8d3d869f56228..a10d31a181c7b 100644 --- a/sycl/test/regression/builtins_vector1.cpp +++ b/sycl/test/regression/builtins_vector1.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/regression/complex_global_object.cpp b/sycl/test/regression/complex_global_object.cpp index f6a190658b718..adee8f97d90c4 100644 --- a/sycl/test/regression/complex_global_object.cpp +++ b/sycl/test/regression/complex_global_object.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=host %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // SYCL runtime may construct global objects at function scope. The test ensures // such objects do not cause problems if the first call to SYCL is inside main diff --git a/sycl/test/regression/fp16-with-unnamed-lambda.cpp b/sycl/test/regression/fp16-with-unnamed-lambda.cpp index 861f5498c465b..b4fadf6e79161 100644 --- a/sycl/test/regression/fp16-with-unnamed-lambda.cpp +++ b/sycl/test/regression/fp16-with-unnamed-lambda.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=host %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include #include diff --git a/sycl/test/regression/global_queue.cpp b/sycl/test/regression/global_queue.cpp index ce4a8102256e0..3e350a13f417a 100644 --- a/sycl/test/regression/global_queue.cpp +++ b/sycl/test/regression/global_queue.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // SYCL dependencies (i.e. low level runtimes) may have global objects of their // own. The test ensures, that those objects do not cause problems. When host diff --git a/sycl/test/regression/group.cpp b/sycl/test/regression/group.cpp index 9ac8f64c7bf42..f36423691e89e 100644 --- a/sycl/test/regression/group.cpp +++ b/sycl/test/regression/group.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==-- group.cpp - Regression tests for cl::sycl::group API bug fixes. -----==// // diff --git a/sycl/test/regression/implicit_atomic_conversion.cpp b/sycl/test/regression/implicit_atomic_conversion.cpp index dbe8210dffb77..7a37747c6dc8f 100644 --- a/sycl/test/regression/implicit_atomic_conversion.cpp +++ b/sycl/test/regression/implicit_atomic_conversion.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/regression/kernel_name_class.cpp b/sycl/test/regression/kernel_name_class.cpp index dfa1572d39a2c..ebe4edbfc7b6c 100644 --- a/sycl/test/regression/kernel_name_class.cpp +++ b/sycl/test/regression/kernel_name_class.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.ext.out -fsycl-unnamed-lambda -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out %t.ext.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out %t.ext.out //==-- kernel_name_class.cpp - SYCL kernel naming variants test ------------==// // diff --git a/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp b/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp index 4f46e3227077a..3c1dedd814a8f 100644 --- a/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp +++ b/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -D__SYCL_DISABLE_NAMESPACE_INLINE__ %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==------- kernel_name_inside_sycl_namespace.cpp - Regression test --------==// // diff --git a/sycl/test/regression/kernel_unnamed.cpp b/sycl/test/regression/kernel_unnamed.cpp index ee797e86ed420..92b1d794f4e6e 100644 --- a/sycl/test/regression/kernel_unnamed.cpp +++ b/sycl/test/regression/kernel_unnamed.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -fsycl-unnamed-lambda -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==-- kernel_unnamed.cpp - SYCL kernel naming variants test ------------==// // diff --git a/sycl/test/regression/msvc_crt.cpp b/sycl/test/regression/msvc_crt.cpp index 8b484f5f7941f..2219573ba3192 100644 --- a/sycl/test/regression/msvc_crt.cpp +++ b/sycl/test/regression/msvc_crt.cpp @@ -1,7 +1,7 @@ // RUN: %clang_cl -fsycl /MD -o %t1.exe %s -// RUN: env SYCL_DEVICE_TYPE=HOST %t1.exe +// RUN: %HOST_RUN_PLACEHOLDER %t1.exe // RUN: %clang_cl -fsycl /MDd -o %t2.exe %s -// RUN: env SYCL_DEVICE_TYPE=HOST %t2.exe +// RUN: %HOST_RUN_PLACEHOLDER %t2.exe // REQUIRES: system-windows //==-------------- msvc_crt.cpp - SYCL MSVC CRT test -----------------------==// // diff --git a/sycl/test/regression/private_array_init_test.cpp b/sycl/test/regression/private_array_init_test.cpp index 82fc6bfe2a788..e793c3967ae0c 100644 --- a/sycl/test/regression/private_array_init_test.cpp +++ b/sycl/test/regression/private_array_init_test.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==- private_array_init_test.cpp - Regression test for private array init -==// // diff --git a/sycl/test/regression/same_unnamed_kernels.cpp b/sycl/test/regression/same_unnamed_kernels.cpp index 6800dda0aabb7..8822badec70a5 100644 --- a/sycl/test/regression/same_unnamed_kernels.cpp +++ b/sycl/test/regression/same_unnamed_kernels.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -fsycl-unnamed-lambda -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==----- same_unnamed_kernels.cpp - SYCL kernel naming variants test ------==// // diff --git a/sycl/test/regression/static-buffer-dtor.cpp b/sycl/test/regression/static-buffer-dtor.cpp index 1f2a25ec9a269..302a238f42b4d 100644 --- a/sycl/test/regression/static-buffer-dtor.cpp +++ b/sycl/test/regression/static-buffer-dtor.cpp @@ -10,7 +10,7 @@ // would start shutting down. //===----------------------------------------------------------------------===// // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out #include diff --git a/sycl/test/regression/sycl-include-gnu11.cpp b/sycl/test/regression/sycl-include-gnu11.cpp index 50e5eaefa50e5..738029f38f430 100644 --- a/sycl/test/regression/sycl-include-gnu11.cpp +++ b/sycl/test/regression/sycl-include-gnu11.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -std=gnu++11 -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out // UNSUPPORTED: system-windows diff --git a/sycl/test/scheduler/BasicSchedulerTests.cpp b/sycl/test/scheduler/BasicSchedulerTests.cpp index 0943cb61e5dbf..ff3c27cd7c5a0 100644 --- a/sycl/test/scheduler/BasicSchedulerTests.cpp +++ b/sycl/test/scheduler/BasicSchedulerTests.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -I %sycl_source_dir %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==------------------- BasicSchedulerTests.cpp ----------------------------==// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. diff --git a/sycl/test/scheduler/ReleaseResourcesTest.cpp b/sycl/test/scheduler/ReleaseResourcesTest.cpp index 4824aaf8f9856..16e9894e701ba 100644 --- a/sycl/test/scheduler/ReleaseResourcesTest.cpp +++ b/sycl/test/scheduler/ReleaseResourcesTest.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -fsycl-dead-args-optimization -I %sycl_source_dir %s -o %t.out -// RUN: env SYCL_DEVICE_TYPE=HOST %t.out +// RUN: %HOST_RUN_PLACEHOLDER %t.out //==------------------- ReleaseResourcesTests.cpp --------------------------==// // From 7588910dfa5c20f2a9a90f8f69a4da496bf2c494 Mon Sep 17 00:00:00 2001 From: Vladimir Lazarev Date: Thu, 19 Nov 2020 08:53:05 +0300 Subject: [PATCH 2/4] Fix clang-format issues --- sycl/test/basic_tests/esimd/vadd.cpp | 7 ++++--- sycl/test/multisource/multisource.cpp | 14 ++++++-------- .../on-device/basic_tests/device_event.cpp | 19 ++++++++++--------- 3 files changed, 20 insertions(+), 20 deletions(-) diff --git a/sycl/test/basic_tests/esimd/vadd.cpp b/sycl/test/basic_tests/esimd/vadd.cpp index 0453a26381be7..1a387d7ffdd81 100644 --- a/sycl/test/basic_tests/esimd/vadd.cpp +++ b/sycl/test/basic_tests/esimd/vadd.cpp @@ -16,9 +16,10 @@ class ESIMDSelector : public device_selector { return device.is_gpu() ? 1000 : -1; if (!strcmp(dev_type, "host")) return device.is_host() ? 1000 : -1; - std::cerr << "Supported 'SYCL_DEVICE_FILTER' env var values are 'gpu' and " - "'host', '" - << dev_type << "' is not.\n"; + std::cerr + << "Supported 'SYCL_DEVICE_FILTER' env var values are 'gpu' and " + "'host', '" + << dev_type << "' is not.\n"; return -1; } // If "SYCL_DEVICE_FILTER" not defined, only allow gpu device diff --git a/sycl/test/multisource/multisource.cpp b/sycl/test/multisource/multisource.cpp index 966b09fbdc504..4ad020912e41a 100644 --- a/sycl/test/multisource/multisource.cpp +++ b/sycl/test/multisource/multisource.cpp @@ -19,7 +19,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %t.init.o %t.calc.o %t.main.o -o %t.fat // RUN: %HOST_RUN_PLACEHOLDER %t.fat - #include #include @@ -27,9 +26,9 @@ using namespace cl::sycl; #ifdef MAIN_APP -void init_buf(queue &q, buffer &b, range<1> &r, int i) ; +void init_buf(queue &q, buffer &b, range<1> &r, int i); #elif INIT_KERNEL -void init_buf(queue &q, buffer &b, range<1> &r, int i){ +void init_buf(queue &q, buffer &b, range<1> &r, int i) { q.submit([&](handler &cgh) { auto B = b.get_access(cgh); cgh.parallel_for(r, [=](id<1> index) { B[index] = i; }); @@ -38,11 +37,11 @@ void init_buf(queue &q, buffer &b, range<1> &r, int i){ #endif #ifdef MAIN_APP -void calc_buf(queue &q, buffer &a, buffer &b, - buffer &c, range<1> &r); +void calc_buf(queue &q, buffer &a, buffer &b, buffer &c, + range<1> &r); #elif CALC_KERNEL -void calc_buf(queue &q, buffer &a, buffer &b, - buffer &c, range<1> &r){ +void calc_buf(queue &q, buffer &a, buffer &b, buffer &c, + range<1> &r) { q.submit([&](handler &cgh) { auto A = a.get_access(cgh); auto B = b.get_access(cgh); @@ -83,4 +82,3 @@ int main() { return 0; } #endif - diff --git a/sycl/test/on-device/basic_tests/device_event.cpp b/sycl/test/on-device/basic_tests/device_event.cpp index 016794df59652..58fcc298085ca 100644 --- a/sycl/test/on-device/basic_tests/device_event.cpp +++ b/sycl/test/on-device/basic_tests/device_event.cpp @@ -2,7 +2,8 @@ // RUN: %GPU_RUN_PLACEHOLDER %t.run // RUN: %CPU_RUN_PLACEHOLDER %t.run // RUN: %ACC_RUN_PLACEHOLDER %t.run -// RUNx (TODO: nd_item::barrier() is not implemented on HOST): %HOST_RUN_PLACEHOLDER %t.run +// TODO: nd_item::barrier() is not implemented on HOST +// RUNx: %HOST_RUN_PLACEHOLDER %t.run //==--------device_event.cpp - SYCL class device_event test ----------------==// // @@ -17,7 +18,7 @@ using namespace cl::sycl; // Define the number of work items to enqueue. -const int nElems = 128*1024u; +const int nElems = 128 * 1024u; const int workGroupSize = 16; // Check the result is correct. @@ -31,8 +32,7 @@ int check_results(int *data, size_t stride) { if ((j % stride) == 0) { expectedVal = 300 + copiedVal; copiedVal++; - } - else { + } else { expectedVal = i + j + 700; } if (data[i + j] != expectedVal) { @@ -62,7 +62,7 @@ int test_strideN(size_t stride) { for (auto ep : l) { try { std::rethrow_exception(ep); - } catch (std::exception& e) { + } catch (std::exception &e) { std::cout << e.what(); } } @@ -70,10 +70,10 @@ int test_strideN(size_t stride) { buffer out_buf(out_data, range<1>(nElems)); - myQueue.submit([&](handler& cgh) { - + myQueue.submit([&](handler &cgh) { auto out_ptr = out_buf.get_access(cgh); - accessor + accessor local_acc(range<1>(16), cgh); // Create work-groups with 16 work items in each group. @@ -100,7 +100,8 @@ int test_strideN(size_t stride) { item.barrier(); // Copy from local memory to global memory. - device_event dev_event = grp.async_work_group_copy(gptr, lptr, nElemsToCopy, stride); + device_event dev_event = + grp.async_work_group_copy(gptr, lptr, nElemsToCopy, stride); grp.wait_for(dev_event); }); From e717fb8b7736d25c9d4817ec8ded9505fb688924 Mon Sep 17 00:00:00 2001 From: Vladimir Lazarev Date: Thu, 19 Nov 2020 16:00:19 +0300 Subject: [PATCH 3/4] Apply review remarks --- sycl/test/CMakeLists.txt | 12 ++--- sycl/test/Unit/lit.cfg.py | 2 +- sycl/test/atomic_ref/accessor.cpp | 2 +- sycl/test/atomic_ref/add.cpp | 2 +- sycl/test/atomic_ref/compare_exchange.cpp | 2 +- sycl/test/atomic_ref/exchange.cpp | 2 +- sycl/test/atomic_ref/load.cpp | 2 +- sycl/test/atomic_ref/max.cpp | 2 +- sycl/test/atomic_ref/min.cpp | 2 +- sycl/test/atomic_ref/store.cpp | 2 +- sycl/test/atomic_ref/sub.cpp | 2 +- .../accessor/accessor_property_list_rt.cpp | 2 +- sycl/test/basic_tests/built-ins.cpp | 2 +- sycl/test/basic_tests/context.cpp | 2 +- sycl/test/basic_tests/device.cpp | 2 +- sycl/test/basic_tests/esimd/vadd.cpp | 12 +++-- .../basic_tests/event_async_exception.cpp | 2 +- .../basic_tests/host_image_accessor_read.cpp | 2 +- sycl/test/basic_tests/linear-host-dev.cpp | 2 +- .../basic_tests/parallel_for_range_host.cpp | 2 +- sycl/test/basic_tests/property_list.cpp | 2 +- sycl/test/basic_tests/reduction_ctor.cpp | 2 +- sycl/test/bit_cast/bit_cast.cpp | 2 +- sycl/test/extensions/usm.cpp | 2 +- .../function-pointers/fp-as-kernel-arg.cpp | 2 +- .../pass-fp-through-buffer.cpp | 2 +- sycl/test/functor/functor_inheritance.cpp | 2 +- sycl/test/functor/kernel_functor.cpp | 2 +- .../array-kernel-param-nested-run.cpp | 2 +- .../kernel_param/array-kernel-param-run.cpp | 2 +- .../test/kernel_param/non-standard-layout.cpp | 2 +- .../test/kernel_param/struct_kernel_param.cpp | 2 +- sycl/test/kernel_param/union_kernel_param.cpp | 2 +- sycl/test/lit.cfg.py | 16 +++--- sycl/test/multi_ptr/multi_ptr.cpp | 4 +- sycl/test/multisource/multisource.cpp | 4 +- .../basic_tests/access_to_subset.cpp | 2 +- sycl/test/on-device/basic_tests/boolean.cpp | 2 +- .../on-device/basic_tests/buffer/buffer.cpp | 4 +- .../basic_tests/buffer/buffer_container.cpp | 4 +- .../basic_tests/buffer/buffer_dev_to_dev.cpp | 2 +- .../basic_tests/buffer/buffer_full_copy.cpp | 4 +- .../basic_tests/buffer/subbuffer.cpp | 2 +- .../on-device/basic_tests/device_equality.cpp | 2 +- .../on-device/basic_tests/device_event.cpp | 2 +- .../basic_tests/diagnostics/device-check.cpp | 50 ------------------- sycl/test/on-device/basic_tests/event.cpp | 2 +- .../on-device/basic_tests/event_creation.cpp | 2 +- .../basic_tests/event_profiling_info.cpp | 2 +- sycl/test/on-device/basic_tests/half_type.cpp | 2 +- .../basic_tests/host_always_works.cpp | 2 +- .../basic_tests/host_platform_avail.cpp | 2 +- sycl/test/on-device/basic_tests/image.cpp | 2 +- .../basic_tests/image/image_read.cpp | 2 +- .../basic_tests/image/image_read_fp16.cpp | 2 +- .../basic_tests/image/image_write.cpp | 2 +- .../basic_tests/image/image_write_fp16.cpp | 2 +- .../image_accessor_readsampler.cpp | 2 +- .../basic_tests/image_accessor_readwrite.cpp | 2 +- .../image_accessor_readwrite_half.cpp | 2 +- .../on-device/basic_tests/image_array.cpp | 2 +- .../basic_tests/image_constructors.cpp | 4 +- sycl/test/on-device/basic_tests/info.cpp | 2 +- .../basic_tests/info_ocl_version.cpp | 2 +- .../basic_tests/parallel_for_indexers.cpp | 4 +- .../basic_tests/scalar_vec_access.cpp | 2 +- .../on-device/basic_tests/stream/stream.cpp | 2 +- sycl/test/on-device/basic_tests/subdevice.cpp | 2 +- .../test/on-device/basic_tests/swizzle_op.cpp | 2 +- .../on-device/basic_tests/sycl-namespace.cpp | 2 +- .../on-device/basic_tests/unused_pointer.cpp | 2 +- .../dot_product/dot_product_int_test.cpp | 2 +- .../dot_product/dot_product_vec_test.cpp | 2 +- .../on-device/hier_par/hier_par_basic.cpp | 2 +- .../on-device/hier_par/hier_par_wgscope.cpp | 2 +- .../hier_par/hier_par_wgscope_O0.cpp | 2 +- .../reduction/reduction_nd_conditional.cpp | 2 +- .../reduction/reduction_nd_ext_double.cpp | 2 +- .../reduction/reduction_nd_ext_half.cpp | 2 +- .../reduction/reduction_nd_lambda.cpp | 2 +- .../reduction/reduction_nd_s0_dw.cpp | 2 +- .../reduction/reduction_nd_s0_rw.cpp | 2 +- .../reduction/reduction_nd_s1_dw.cpp | 2 +- .../reduction/reduction_nd_s1_rw.cpp | 2 +- .../reduction/reduction_placeholder.cpp | 2 +- .../reduction_queue_parallel_for.cpp | 2 +- .../reduction/reduction_transparent.cpp | 2 +- .../on-device/reduction/reduction_usm.cpp | 2 +- .../regression/usm_malloc_shared.cpp | 2 +- .../on-device/spec_const/spec_const_hw.cpp | 2 +- .../on-device/spec_const/spec_const_neg.cpp | 2 +- .../spec_const/spec_const_redefine.cpp | 2 +- sycl/test/on-device/sub_group/attributes.cpp | 2 +- sycl/test/on-device/sub_group/barrier.cpp | 2 +- sycl/test/on-device/sub_group/broadcast.cpp | 2 +- .../on-device/sub_group/broadcast_fp64.cpp | 2 +- sycl/test/on-device/sub_group/common.cpp | 2 +- .../on-device/sub_group/generic-shuffle.cpp | 2 +- .../on-device/sub_group/generic_reduce.cpp | 2 +- sycl/test/on-device/sub_group/info.cpp | 2 +- sycl/test/on-device/sub_group/load_store.cpp | 2 +- sycl/test/on-device/sub_group/reduce.cpp | 2 +- sycl/test/on-device/sub_group/reduce_fp64.cpp | 2 +- sycl/test/on-device/sub_group/scan.cpp | 2 +- sycl/test/on-device/sub_group/scan_fp64.cpp | 2 +- sycl/test/on-device/sub_group/shuffle.cpp | 2 +- .../test/on-device/sub_group/shuffle_fp64.cpp | 2 +- sycl/test/on-device/sub_group/vote.cpp | 2 +- sycl/test/regression/atomic_load.cpp | 2 +- sycl/test/regression/builtins_vector1.cpp | 2 +- .../test/regression/complex_global_object.cpp | 2 +- .../regression/fp16-with-unnamed-lambda.cpp | 2 +- sycl/test/regression/global_queue.cpp | 2 +- sycl/test/regression/group.cpp | 2 +- .../regression/implicit_atomic_conversion.cpp | 2 +- sycl/test/regression/kernel_name_class.cpp | 4 +- .../kernel_name_inside_sycl_namespace.cpp | 2 +- sycl/test/regression/kernel_unnamed.cpp | 2 +- sycl/test/regression/msvc_crt.cpp | 4 +- .../regression/private_array_init_test.cpp | 2 +- sycl/test/regression/same_unnamed_kernels.cpp | 2 +- sycl/test/regression/static-buffer-dtor.cpp | 2 +- sycl/test/regression/sycl-include-gnu11.cpp | 2 +- sycl/test/scheduler/BasicSchedulerTests.cpp | 2 +- sycl/test/scheduler/ReleaseResourcesTest.cpp | 2 +- 125 files changed, 151 insertions(+), 199 deletions(-) delete mode 100644 sycl/test/on-device/basic_tests/diagnostics/device-check.cpp diff --git a/sycl/test/CMakeLists.txt b/sycl/test/CMakeLists.txt index eaf842a6fb94f..c299370174788 100644 --- a/sycl/test/CMakeLists.txt +++ b/sycl/test/CMakeLists.txt @@ -45,7 +45,7 @@ list(APPEND SYCL_DEPLOY_TEST_DEPS add_lit_testsuite(check-sycl-deploy "Running the SYCL regression tests" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${DEPLOY_RT_TEST_ARGS} - PARAMS "SYCL_BE=opencl" + PARAMS "SYCL_PLUGIN=opencl" DEPENDS ${SYCL_DEPLOY_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -58,7 +58,7 @@ add_lit_testsuites(SYCL ${CMAKE_CURRENT_SOURCE_DIR} add_lit_testsuites(SYCL-DEPLOY ${CMAKE_CURRENT_SOURCE_DIR} ARGS ${DEPLOY_RT_TEST_ARGS} - PARAMS "SYCL_BE=opencl" + PARAMS "SYCL_PLUGIN=opencl" DEPENDS ${SYCL_DEPLOY_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -66,7 +66,7 @@ add_lit_testsuites(SYCL-DEPLOY ${CMAKE_CURRENT_SOURCE_DIR} add_lit_testsuite(check-sycl-opencl "Running the SYCL regression tests for OpenCL" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${RT_TEST_ARGS} - PARAMS "SYCL_BE=opencl" + PARAMS "SYCL_PLUGIN=opencl" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -75,7 +75,7 @@ set_target_properties(check-sycl-opencl PROPERTIES FOLDER "SYCL tests") add_lit_testsuite(check-sycl-level-zero "Running the SYCL regression tests for Level Zero" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${RT_TEST_ARGS} - PARAMS "SYCL_BE=level_zero" + PARAMS "SYCL_PLUGIN=level_zero" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -89,7 +89,7 @@ if(SYCL_BUILD_PI_CUDA) add_lit_testsuite(check-sycl-cuda "Running the SYCL regression tests for CUDA" ${CMAKE_CURRENT_BINARY_DIR} ARGS ${RT_TEST_ARGS} - PARAMS "SYCL_BE=cuda" + PARAMS "SYCL_PLUGIN=cuda" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) @@ -98,7 +98,7 @@ if(SYCL_BUILD_PI_CUDA) add_dependencies(check-sycl check-sycl-cuda) add_lit_testsuites(SYCL-CUDA ${CMAKE_CURRENT_SOURCE_DIR} - PARAMS "SYCL_BE=cuda" + PARAMS "SYCL_PLUGIN=cuda" DEPENDS ${SYCL_TEST_DEPS} EXCLUDE_FROM_CHECK_ALL ) diff --git a/sycl/test/Unit/lit.cfg.py b/sycl/test/Unit/lit.cfg.py index ed0b0e07a10c0..2dbc0d14e9f21 100644 --- a/sycl/test/Unit/lit.cfg.py +++ b/sycl/test/Unit/lit.cfg.py @@ -73,5 +73,5 @@ def find_shlibpath_var(): lit_config.warning("unable to inject shared library path on '{}'" .format(platform.system())) -config.environment['SYCL_DEVICE_FILTER'] = lit_config.params.get('SYCL_BE', "opencl") +config.environment['SYCL_DEVICE_FILTER'] = lit_config.params.get('SYCL_PLUGIN', "opencl") lit_config.note("Backend: {}".format(config.environment['SYCL_DEVICE_FILTER'])) diff --git a/sycl/test/atomic_ref/accessor.cpp b/sycl/test/atomic_ref/accessor.cpp index ed04aad595e6e..f9f3278628cc5 100644 --- a/sycl/test/atomic_ref/accessor.cpp +++ b/sycl/test/atomic_ref/accessor.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/add.cpp b/sycl/test/atomic_ref/add.cpp index cfcfd25e89b4c..b678198a6a20e 100644 --- a/sycl/test/atomic_ref/add.cpp +++ b/sycl/test/atomic_ref/add.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/compare_exchange.cpp b/sycl/test/atomic_ref/compare_exchange.cpp index 5b84ce62c0fed..026138127e206 100644 --- a/sycl/test/atomic_ref/compare_exchange.cpp +++ b/sycl/test/atomic_ref/compare_exchange.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/exchange.cpp b/sycl/test/atomic_ref/exchange.cpp index db9524ec58bd9..62f03bee1f989 100644 --- a/sycl/test/atomic_ref/exchange.cpp +++ b/sycl/test/atomic_ref/exchange.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/load.cpp b/sycl/test/atomic_ref/load.cpp index a8da04e7a790d..e05cdce576d3e 100644 --- a/sycl/test/atomic_ref/load.cpp +++ b/sycl/test/atomic_ref/load.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/max.cpp b/sycl/test/atomic_ref/max.cpp index d783e973de77e..8b003ca7b59ad 100644 --- a/sycl/test/atomic_ref/max.cpp +++ b/sycl/test/atomic_ref/max.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/min.cpp b/sycl/test/atomic_ref/min.cpp index 4be8cabe9f28a..4b6c20fc1a809 100644 --- a/sycl/test/atomic_ref/min.cpp +++ b/sycl/test/atomic_ref/min.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/store.cpp b/sycl/test/atomic_ref/store.cpp index 73ed1114aa591..6f9de6e032e36 100644 --- a/sycl/test/atomic_ref/store.cpp +++ b/sycl/test/atomic_ref/store.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/atomic_ref/sub.cpp b/sycl/test/atomic_ref/sub.cpp index cfbdd1a41b160..a09de3c710bcb 100644 --- a/sycl/test/atomic_ref/sub.cpp +++ b/sycl/test/atomic_ref/sub.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp b/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp index ec3926f5d2874..ec3e80d7b37eb 100644 --- a/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp +++ b/sycl/test/basic_tests/accessor/accessor_property_list_rt.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/basic_tests/built-ins.cpp b/sycl/test/basic_tests/built-ins.cpp index 140facfb51a6e..fe209a7685f11 100644 --- a/sycl/test/basic_tests/built-ins.cpp +++ b/sycl/test/basic_tests/built-ins.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // CUDA does not support printf. // UNSUPPORTED: cuda diff --git a/sycl/test/basic_tests/context.cpp b/sycl/test/basic_tests/context.cpp index 3ef945415fe63..a376beff527e3 100644 --- a/sycl/test/basic_tests/context.cpp +++ b/sycl/test/basic_tests/context.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx %s -o %t.out -lsycl -I %sycl_include -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==--------------- context.cpp - SYCL context test ------------------------==// // diff --git a/sycl/test/basic_tests/device.cpp b/sycl/test/basic_tests/device.cpp index 5b88034a1e832..0b84d40de236a 100644 --- a/sycl/test/basic_tests/device.cpp +++ b/sycl/test/basic_tests/device.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx %s -o %t.out -I %sycl_include -lsycl -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==--------------- device.cpp - SYCL device test --------------------------==// // diff --git a/sycl/test/basic_tests/esimd/vadd.cpp b/sycl/test/basic_tests/esimd/vadd.cpp index 1a387d7ffdd81..68208337d2eb2 100644 --- a/sycl/test/basic_tests/esimd/vadd.cpp +++ b/sycl/test/basic_tests/esimd/vadd.cpp @@ -1,25 +1,27 @@ // TODO ESIMD enable host device under -fsycl // RUN: %clangxx -I %sycl_include %s -o %t.out -lsycl -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include #include +#include using namespace cl::sycl; class ESIMDSelector : public device_selector { // Require GPU device unless HOST is requested in SYCL_DEVICE_FILTER env virtual int operator()(const device &device) const { - if (const char *dev_type = getenv("SYCL_DEVICE_FILTER")) { - if (!strcmp(dev_type, "gpu")) + if (const char *dev_filter = getenv("SYCL_DEVICE_FILTER")) { + std::string filter_string(dev_filter); + if (filter_string.find("gpu") != std::string::npos) return device.is_gpu() ? 1000 : -1; - if (!strcmp(dev_type, "host")) + if (filter_string.find("host") != std::string::npos) return device.is_host() ? 1000 : -1; std::cerr << "Supported 'SYCL_DEVICE_FILTER' env var values are 'gpu' and " "'host', '" - << dev_type << "' is not.\n"; + << filter_string << "' does not contain such substrings.\n"; return -1; } // If "SYCL_DEVICE_FILTER" not defined, only allow gpu device diff --git a/sycl/test/basic_tests/event_async_exception.cpp b/sycl/test/basic_tests/event_async_exception.cpp index e94c3eb26e74a..1f39ebd20e5fb 100644 --- a/sycl/test/basic_tests/event_async_exception.cpp +++ b/sycl/test/basic_tests/event_async_exception.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==---- event_async_exception.cpp - Test for event async exceptions -------==// // diff --git a/sycl/test/basic_tests/host_image_accessor_read.cpp b/sycl/test/basic_tests/host_image_accessor_read.cpp index 3ffc3fac59f4a..2bcd820b77bfc 100644 --- a/sycl/test/basic_tests/host_image_accessor_read.cpp +++ b/sycl/test/basic_tests/host_image_accessor_read.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==---- host_image_accessor_read.cpp - SYCL host image accessor check ----==// // diff --git a/sycl/test/basic_tests/linear-host-dev.cpp b/sycl/test/basic_tests/linear-host-dev.cpp index 0e279d926e384..2f7843941bdd9 100644 --- a/sycl/test/basic_tests/linear-host-dev.cpp +++ b/sycl/test/basic_tests/linear-host-dev.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out | FileCheck %s +// RUN: %RUN_ON_HOST %t.out | FileCheck %s #include #include diff --git a/sycl/test/basic_tests/parallel_for_range_host.cpp b/sycl/test/basic_tests/parallel_for_range_host.cpp index d2cf3f0cbd1f7..27b02ca58949a 100644 --- a/sycl/test/basic_tests/parallel_for_range_host.cpp +++ b/sycl/test/basic_tests/parallel_for_range_host.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/basic_tests/property_list.cpp b/sycl/test/basic_tests/property_list.cpp index c42bf6b9b29ab..0150fb92daabc 100644 --- a/sycl/test/basic_tests/property_list.cpp +++ b/sycl/test/basic_tests/property_list.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx %s -o %t.out -lsycl -I%sycl_include -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // // CHECK: PASSED //==--------------- property_list.cpp - SYCL property list test ------------==// diff --git a/sycl/test/basic_tests/reduction_ctor.cpp b/sycl/test/basic_tests/reduction_ctor.cpp index 9b862e392a734..7764f937d03db 100644 --- a/sycl/test/basic_tests/reduction_ctor.cpp +++ b/sycl/test/basic_tests/reduction_ctor.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // This performs basic checks such as reduction creation, getIdentity() method, // and the combine() method of the aux class 'reducer'. diff --git a/sycl/test/bit_cast/bit_cast.cpp b/sycl/test/bit_cast/bit_cast.cpp index 849f8c5250c95..f383bf70ca313 100644 --- a/sycl/test/bit_cast/bit_cast.cpp +++ b/sycl/test/bit_cast/bit_cast.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/extensions/usm.cpp b/sycl/test/extensions/usm.cpp index c50edbb12e6d1..a03c9201fbb57 100644 --- a/sycl/test/extensions/usm.cpp +++ b/sycl/test/extensions/usm.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t1.out -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out //==---------- allocator_equal.cpp - Allocator Equality test ---------------==// // diff --git a/sycl/test/function-pointers/fp-as-kernel-arg.cpp b/sycl/test/function-pointers/fp-as-kernel-arg.cpp index 0ed67480f9298..5973c2b419bc8 100644 --- a/sycl/test/function-pointers/fp-as-kernel-arg.cpp +++ b/sycl/test/function-pointers/fp-as-kernel-arg.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -Xclang -fsycl-allow-func-ptr -std=c++14 -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // FIXME: This test should use runtime early exit once correct check for // corresponding extension is implemented diff --git a/sycl/test/function-pointers/pass-fp-through-buffer.cpp b/sycl/test/function-pointers/pass-fp-through-buffer.cpp index f6215c5116da5..60ca4cd5f4c71 100644 --- a/sycl/test/function-pointers/pass-fp-through-buffer.cpp +++ b/sycl/test/function-pointers/pass-fp-through-buffer.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -Xclang -fsycl-allow-func-ptr -std=c++14 -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // FIXME: This test should use runtime early exit once correct check for // corresponding extension is implemented diff --git a/sycl/test/functor/functor_inheritance.cpp b/sycl/test/functor/functor_inheritance.cpp index d7e639cbef090..c96e2efcd0f92 100644 --- a/sycl/test/functor/functor_inheritance.cpp +++ b/sycl/test/functor/functor_inheritance.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -o %t.out %s -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/functor/kernel_functor.cpp b/sycl/test/functor/kernel_functor.cpp index 18f59b122b39f..fe70853226696 100644 --- a/sycl/test/functor/kernel_functor.cpp +++ b/sycl/test/functor/kernel_functor.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -o %t.out %s // RUN: cd %T -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==--- kernel_functor.cpp - Functors as SYCL kernel test ------------------==// // diff --git a/sycl/test/kernel_param/array-kernel-param-nested-run.cpp b/sycl/test/kernel_param/array-kernel-param-nested-run.cpp index 86deaa64e6b9b..f27ea5f607db7 100755 --- a/sycl/test/kernel_param/array-kernel-param-nested-run.cpp +++ b/sycl/test/kernel_param/array-kernel-param-nested-run.cpp @@ -1,7 +1,7 @@ // This test checks kernel execution with array parameters inside structs. // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/kernel_param/array-kernel-param-run.cpp b/sycl/test/kernel_param/array-kernel-param-run.cpp index 0212d4503d00a..ab79b4590c557 100755 --- a/sycl/test/kernel_param/array-kernel-param-run.cpp +++ b/sycl/test/kernel_param/array-kernel-param-run.cpp @@ -1,7 +1,7 @@ // This test checks kernel execution with array kernel parameters. // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/kernel_param/non-standard-layout.cpp b/sycl/test/kernel_param/non-standard-layout.cpp index ece0afde868ae..31ece6d0f34af 100644 --- a/sycl/test/kernel_param/non-standard-layout.cpp +++ b/sycl/test/kernel_param/non-standard-layout.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/kernel_param/struct_kernel_param.cpp b/sycl/test/kernel_param/struct_kernel_param.cpp index 378369d0a5af1..0c6c278a4f1ec 100644 --- a/sycl/test/kernel_param/struct_kernel_param.cpp +++ b/sycl/test/kernel_param/struct_kernel_param.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==-struct_kernel_param.cpp-Checks passing structs as kernel params--------==// // diff --git a/sycl/test/kernel_param/union_kernel_param.cpp b/sycl/test/kernel_param/union_kernel_param.cpp index fe567cc32aa74..4290467ac1362 100644 --- a/sycl/test/kernel_param/union_kernel_param.cpp +++ b/sycl/test/kernel_param/union_kernel_param.cpp @@ -1,7 +1,7 @@ // This test checks kernel execution with union type as kernel parameters. // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/lit.cfg.py b/sycl/test/lit.cfg.py index ac0cb500d5bad..00f46f774cf32 100644 --- a/sycl/test/lit.cfg.py +++ b/sycl/test/lit.cfg.py @@ -75,11 +75,11 @@ llvm_config.add_tool_substitutions(['llvm-spirv'], [config.sycl_tools_dir]) -backend=lit_config.params.get('SYCL_BE', "opencl") +backend=lit_config.params.get('SYCL_PLUGIN', "opencl") lit_config.note("Backend: {}".format(backend)) config.substitutions.append( ('%sycl_be', { 'opencl': 'PI_OPENCL', 'cuda': 'PI_CUDA', 'level_zero': 'PI_LEVEL_ZERO'}[backend]) ) -config.substitutions.append( ('%BE_RUN_PLACEHOLDER', "env SYCL_DEVICE_FILTER={SYCL_BE} ".format(SYCL_BE=backend)) ) -config.substitutions.append( ('%HOST_RUN_PLACEHOLDER', "env SYCL_DEVICE_FILTER=host ") ) +config.substitutions.append( ('%BE_RUN_PLACEHOLDER', "env SYCL_DEVICE_FILTER={SYCL_PLUGIN} ".format(SYCL_PLUGIN=backend)) ) +config.substitutions.append( ('%RUN_ON_HOST', "env SYCL_DEVICE_FILTER=host ") ) get_device_count_by_type_path = os.path.join(config.llvm_tools_dir, "get_device_count_by_type") @@ -133,11 +133,11 @@ def getDeviceCount(device_type): if getDeviceCount("cpu")[0]: found_at_least_one_device = True lit_config.note("Found available CPU device") - cpu_run_substitute = "env SYCL_DEVICE_FILTER={SYCL_BE}:cpu ".format(SYCL_BE=backend) + cpu_run_substitute = "env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:cpu ".format(SYCL_PLUGIN=backend) cpu_check_substitute = "| FileCheck %s" config.available_features.add('cpu') if platform.system() == "Linux": - cpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_BE}:cpu ".format(SYCL_BE=backend) + cpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:cpu ".format(SYCL_PLUGIN=backend) cpu_check_on_linux_substitute = "| FileCheck %s" else: lit_config.warning("CPU device not found") @@ -159,7 +159,7 @@ def getDeviceCount(device_type): if gpu_count > 0: found_at_least_one_device = True lit_config.note("Found available GPU device") - gpu_run_substitute = " env SYCL_DEVICE_FILTER={SYCL_BE}:gpu ".format(SYCL_BE=backend) + gpu_run_substitute = " env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:gpu ".format(SYCL_PLUGIN=backend) gpu_check_substitute = "| FileCheck %s" config.available_features.add('gpu') if cuda: @@ -168,7 +168,7 @@ def getDeviceCount(device_type): config.available_features.add('level_zero') if platform.system() == "Linux": - gpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_BE}:gpu ".format(SYCL_BE=backend) + gpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:gpu ".format(SYCL_PLUGIN=backend) gpu_check_on_linux_substitute = "| FileCheck %s" # ESIMD-specific setup. Requires OpenCL for now. esimd_run_substitute = " env SYCL_DEVICE_FILTER=opencl:gpu SYCL_PROGRAM_COMPILE_OPTIONS=-vc-codegen" @@ -187,7 +187,7 @@ def getDeviceCount(device_type): if getDeviceCount("accelerator")[0]: found_at_least_one_device = True lit_config.note("Found available accelerator device") - acc_run_substitute = " env SYCL_DEVICE_FILTER={SYCL_BE}:acc ".format(SYCL_BE=backend) + acc_run_substitute = " env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:acc ".format(SYCL_PLUGIN=backend) acc_check_substitute = "| FileCheck %s" config.available_features.add('accelerator') else: diff --git a/sycl/test/multi_ptr/multi_ptr.cpp b/sycl/test/multi_ptr/multi_ptr.cpp index 50a1d88c495ab..2c011872fff58 100644 --- a/sycl/test/multi_ptr/multi_ptr.cpp +++ b/sycl/test/multi_ptr/multi_ptr.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -fsycl-dead-args-optimization %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %clangxx -DRESTRICT_WRITE_ACCESS_TO_CONSTANT_PTR -fsycl -fsycl-targets=%sycl_triple -fsycl-dead-args-optimization %s -o %t1.out -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out //==--------------- multi_ptr.cpp - SYCL multi_ptr test --------------------==// // diff --git a/sycl/test/multisource/multisource.cpp b/sycl/test/multisource/multisource.cpp index 4ad020912e41a..ef6a882d778a1 100644 --- a/sycl/test/multisource/multisource.cpp +++ b/sycl/test/multisource/multisource.cpp @@ -10,14 +10,14 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.kernel.o %s -DINIT_KERNEL -DCALC_KERNEL // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.main.o %s -DMAIN_APP // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %t.kernel.o %t.main.o -o %t.fat -// RUN: %HOST_RUN_PLACEHOLDER %t.fat +// RUN: %RUN_ON_HOST %t.fat // Multiple sources with kernel code // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.init.o %s -DINIT_KERNEL // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.calc.o %s -DCALC_KERNEL // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -c -o %t.main.o %s -DMAIN_APP // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %t.init.o %t.calc.o %t.main.o -o %t.fat -// RUN: %HOST_RUN_PLACEHOLDER %t.fat +// RUN: %RUN_ON_HOST %t.fat #include diff --git a/sycl/test/on-device/basic_tests/access_to_subset.cpp b/sycl/test/on-device/basic_tests/access_to_subset.cpp index b0a80f8567cb6..a9e64755631e5 100644 --- a/sycl/test/on-device/basic_tests/access_to_subset.cpp +++ b/sycl/test/on-device/basic_tests/access_to_subset.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/boolean.cpp b/sycl/test/on-device/basic_tests/boolean.cpp index cd2b7388cc314..eaeb3d7dcbdb7 100644 --- a/sycl/test/on-device/basic_tests/boolean.cpp +++ b/sycl/test/on-device/basic_tests/boolean.cpp @@ -3,7 +3,7 @@ // XFAIL: gpu && (level_zero || opencl) // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer.cpp b/sycl/test/on-device/basic_tests/buffer/buffer.cpp index 96a2102ccfbd2..ce357f188c9ff 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: %HOST_RUN_PLACEHOLDER %t2.out +// RUN: %RUN_ON_HOST %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp b/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp index 84bb92312d1fe..bb25092a329c7 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer_container.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -std=c++17 -o %t1.out -lsycl -I %sycl_include -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %clangxx -std=c++17 -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: %HOST_RUN_PLACEHOLDER %t2.out +// RUN: %RUN_ON_HOST %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp b/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp index 9feca8f4b2f39..c95ecc13d8724 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer_dev_to_dev.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp b/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp index 3d204bce5fd23..c7bc615f64f8e 100644 --- a/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp +++ b/sycl/test/on-device/basic_tests/buffer/buffer_full_copy.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: %HOST_RUN_PLACEHOLDER %t2.out +// RUN: %RUN_ON_HOST %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp b/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp index 39a43bb7f3c51..39fcd590beea9 100644 --- a/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp +++ b/sycl/test/on-device/basic_tests/buffer/subbuffer.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/device_equality.cpp b/sycl/test/on-device/basic_tests/device_equality.cpp index 24b27c63db078..0600e8b064268 100644 --- a/sycl/test/on-device/basic_tests/device_equality.cpp +++ b/sycl/test/on-device/basic_tests/device_equality.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t1.out -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %CPU_RUN_PLACEHOLDER %t1.out // RUN: %GPU_RUN_PLACEHOLDER %t1.out diff --git a/sycl/test/on-device/basic_tests/device_event.cpp b/sycl/test/on-device/basic_tests/device_event.cpp index 58fcc298085ca..8995c06ffdf7f 100644 --- a/sycl/test/on-device/basic_tests/device_event.cpp +++ b/sycl/test/on-device/basic_tests/device_event.cpp @@ -3,7 +3,7 @@ // RUN: %CPU_RUN_PLACEHOLDER %t.run // RUN: %ACC_RUN_PLACEHOLDER %t.run // TODO: nd_item::barrier() is not implemented on HOST -// RUNx: %HOST_RUN_PLACEHOLDER %t.run +// RUNx: %RUN_ON_HOST %t.run //==--------device_event.cpp - SYCL class device_event test ----------------==// // diff --git a/sycl/test/on-device/basic_tests/diagnostics/device-check.cpp b/sycl/test/on-device/basic_tests/diagnostics/device-check.cpp deleted file mode 100644 index e15854fdc05b3..0000000000000 --- a/sycl/test/on-device/basic_tests/diagnostics/device-check.cpp +++ /dev/null @@ -1,50 +0,0 @@ -// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=cpu %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=gpu %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=acc %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=host %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=CPU %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=GPU %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=ACC %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=HOST %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Cpu %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Gpu %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Acc %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Host %t.out -// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=XPU %t.out - -//==------------------- device-check.cpp --------------------------==// -// This is a diagnostic test which ensures that -// device types are case-insensitive. -// It also checks for SYCL_DEVICE being set incorrectly. -//==---------------------------------------------------------------==// - -#include -#include - -using namespace cl::sycl; - - -int main() { - try { - queue q = queue(); - auto device = q.get_device(); - auto deviceName = device.get_info(); - std::cout << " Device Name: " << deviceName << std::endl; - } - - catch (runtime_error &E) { - if (std::string(E.what()).find( - "SYCL_DEVICE_TYPE is not recognized. Must be GPU, CPU, ACC or HOST.") == - std::string::npos) { - std::cout << "Test failed: received error is incorrect." << std::endl; - return 1; - } else { - std::cout << "Test passed: caught the expected error." << std::endl; - return 0; - } - } - - std::cout << "Test passed: results are correct." << std::endl; - return 0; -} diff --git a/sycl/test/on-device/basic_tests/event.cpp b/sycl/test/on-device/basic_tests/event.cpp index 1d365a596cc68..fcfe5095af1cb 100644 --- a/sycl/test/on-device/basic_tests/event.cpp +++ b/sycl/test/on-device/basic_tests/event.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/event_creation.cpp b/sycl/test/on-device/basic_tests/event_creation.cpp index 33f3e551b9063..aa190deeccd59 100644 --- a/sycl/test/on-device/basic_tests/event_creation.cpp +++ b/sycl/test/on-device/basic_tests/event_creation.cpp @@ -1,7 +1,7 @@ // REQUIRES: opencl // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -L %opencl_libs_dir -lOpenCL -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/event_profiling_info.cpp b/sycl/test/on-device/basic_tests/event_profiling_info.cpp index df8fb9f6af9e9..0a9eee7ca7af5 100644 --- a/sycl/test/on-device/basic_tests/event_profiling_info.cpp +++ b/sycl/test/on-device/basic_tests/event_profiling_info.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out // -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/half_type.cpp b/sycl/test/on-device/basic_tests/half_type.cpp index bc2f768cd083e..a3bcdf98f7cb9 100644 --- a/sycl/test/on-device/basic_tests/half_type.cpp +++ b/sycl/test/on-device/basic_tests/half_type.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/host_always_works.cpp b/sycl/test/on-device/basic_tests/host_always_works.cpp index e2cfbc08c7a7f..bb61b6e6a7b10 100644 --- a/sycl/test/on-device/basic_tests/host_always_works.cpp +++ b/sycl/test/on-device/basic_tests/host_always_works.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t1.out -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %CPU_RUN_PLACEHOLDER %t1.out // RUN: %GPU_RUN_PLACEHOLDER %t1.out // RUN: %ACC_RUN_PLACEHOLDER %t1.out diff --git a/sycl/test/on-device/basic_tests/host_platform_avail.cpp b/sycl/test/on-device/basic_tests/host_platform_avail.cpp index e4097d40f7bc7..d30c475a4022c 100644 --- a/sycl/test/on-device/basic_tests/host_platform_avail.cpp +++ b/sycl/test/on-device/basic_tests/host_platform_avail.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t1.out -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %CPU_RUN_PLACEHOLDER %t1.out // RUN: %GPU_RUN_PLACEHOLDER %t1.out // RUN: %ACC_RUN_PLACEHOLDER %t1.out diff --git a/sycl/test/on-device/basic_tests/image.cpp b/sycl/test/on-device/basic_tests/image.cpp index 02f052003a2a9..c4f17654b1a47 100644 --- a/sycl/test/on-device/basic_tests/image.cpp +++ b/sycl/test/on-device/basic_tests/image.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_read.cpp b/sycl/test/on-device/basic_tests/image/image_read.cpp index d4368c589273a..222827ba84462 100644 --- a/sycl/test/on-device/basic_tests/image/image_read.cpp +++ b/sycl/test/on-device/basic_tests/image/image_read.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp b/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp index 7ecf548d442d8..1dffd2cdae9e6 100644 --- a/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp +++ b/sycl/test/on-device/basic_tests/image/image_read_fp16.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_write.cpp b/sycl/test/on-device/basic_tests/image/image_write.cpp index ef9a7fd6246af..50ef4995d4849 100644 --- a/sycl/test/on-device/basic_tests/image/image_write.cpp +++ b/sycl/test/on-device/basic_tests/image/image_write.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp b/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp index d0f52b370bed7..f3096ab73a4df 100644 --- a/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp +++ b/sycl/test/on-device/basic_tests/image/image_write_fp16.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp b/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp index 925a767f606e9..4b73caa05ccee 100644 --- a/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp +++ b/sycl/test/on-device/basic_tests/image_accessor_readsampler.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // diff --git a/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp b/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp index 519e6b10eaa1f..f0e115809208d 100644 --- a/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp +++ b/sycl/test/on-device/basic_tests/image_accessor_readwrite.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp b/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp index ff88d3bbc79e0..089585020cc2b 100644 --- a/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp +++ b/sycl/test/on-device/basic_tests/image_accessor_readwrite_half.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_array.cpp b/sycl/test/on-device/basic_tests/image_array.cpp index 3f93d51c2d282..cc0ff5af48b96 100644 --- a/sycl/test/on-device/basic_tests/image_array.cpp +++ b/sycl/test/on-device/basic_tests/image_array.cpp @@ -2,7 +2,7 @@ // CUDA cannot support SYCL 1.2.1 images. // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUNx: %GPU_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/image_constructors.cpp b/sycl/test/on-device/basic_tests/image_constructors.cpp index f9759bb744f7d..f2945a196ae4a 100644 --- a/sycl/test/on-device/basic_tests/image_constructors.cpp +++ b/sycl/test/on-device/basic_tests/image_constructors.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: %HOST_RUN_PLACEHOLDER %t2.out +// RUN: %RUN_ON_HOST %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/info.cpp b/sycl/test/on-device/basic_tests/info.cpp index ddcd420f813ff..6ab192967e891 100644 --- a/sycl/test/on-device/basic_tests/info.cpp +++ b/sycl/test/on-device/basic_tests/info.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/info_ocl_version.cpp b/sycl/test/on-device/basic_tests/info_ocl_version.cpp index 46ea03fb33c9e..f64f853b44435 100644 --- a/sycl/test/on-device/basic_tests/info_ocl_version.cpp +++ b/sycl/test/on-device/basic_tests/info_ocl_version.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: env %CPU_RUN_PLACEHOLDER %t.out // RUN: env %GPU_RUN_PLACEHOLDER %t.out // RUN: env %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp b/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp index e4b58dedbb608..6c671159ca107 100644 --- a/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp +++ b/sycl/test/on-device/basic_tests/parallel_for_indexers.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx %s -o %t1.out -lsycl -I %sycl_include -Wno-sycl-strict -Xclang -verify-ignore-unexpected=note,warning -// RUN: %HOST_RUN_PLACEHOLDER %t1.out +// RUN: %RUN_ON_HOST %t1.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out -// RUN: %HOST_RUN_PLACEHOLDER %t2.out +// RUN: %RUN_ON_HOST %t2.out // RUN: %CPU_RUN_PLACEHOLDER %t2.out // RUN: %GPU_RUN_PLACEHOLDER %t2.out // RUN: %ACC_RUN_PLACEHOLDER %t2.out diff --git a/sycl/test/on-device/basic_tests/scalar_vec_access.cpp b/sycl/test/on-device/basic_tests/scalar_vec_access.cpp index 4e2277448e1c0..8b84a4ec18152 100644 --- a/sycl/test/on-device/basic_tests/scalar_vec_access.cpp +++ b/sycl/test/on-device/basic_tests/scalar_vec_access.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out | FileCheck %s +// RUN: %RUN_ON_HOST %t.out | FileCheck %s // RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER // RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER // RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER diff --git a/sycl/test/on-device/basic_tests/stream/stream.cpp b/sycl/test/on-device/basic_tests/stream/stream.cpp index 9451d575db394..866636fbc1991 100644 --- a/sycl/test/on-device/basic_tests/stream/stream.cpp +++ b/sycl/test/on-device/basic_tests/stream/stream.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out | FileCheck %s +// RUN: %RUN_ON_HOST %t.out | FileCheck %s // RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER // RUN: %GPU_RUN_ON_LINUX_PLACEHOLDER %t.out %GPU_CHECK_ON_LINUX_PLACEHOLDER // RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER diff --git a/sycl/test/on-device/basic_tests/subdevice.cpp b/sycl/test/on-device/basic_tests/subdevice.cpp index fca3abd7f998d..56a78197a58cf 100644 --- a/sycl/test/on-device/basic_tests/subdevice.cpp +++ b/sycl/test/on-device/basic_tests/subdevice.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/swizzle_op.cpp b/sycl/test/on-device/basic_tests/swizzle_op.cpp index abfcee0303ef3..ee2e514bacbd6 100644 --- a/sycl/test/on-device/basic_tests/swizzle_op.cpp +++ b/sycl/test/on-device/basic_tests/swizzle_op.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/sycl-namespace.cpp b/sycl/test/on-device/basic_tests/sycl-namespace.cpp index 3304bb4464604..9cfba72e8e4bd 100644 --- a/sycl/test/on-device/basic_tests/sycl-namespace.cpp +++ b/sycl/test/on-device/basic_tests/sycl-namespace.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/basic_tests/unused_pointer.cpp b/sycl/test/on-device/basic_tests/unused_pointer.cpp index 8583943a916b0..75118e8fb5549 100644 --- a/sycl/test/on-device/basic_tests/unused_pointer.cpp +++ b/sycl/test/on-device/basic_tests/unused_pointer.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/dot_product/dot_product_int_test.cpp b/sycl/test/on-device/dot_product/dot_product_int_test.cpp index c6eaec1002bff..4110459ee1bba 100755 --- a/sycl/test/on-device/dot_product/dot_product_int_test.cpp +++ b/sycl/test/on-device/dot_product/dot_product_int_test.cpp @@ -2,7 +2,7 @@ // For now we only check fallback support because DG1 hardware is not widespread // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/dot_product/dot_product_vec_test.cpp b/sycl/test/on-device/dot_product/dot_product_vec_test.cpp index 37570df1783c6..00f0a338a4af9 100644 --- a/sycl/test/on-device/dot_product/dot_product_vec_test.cpp +++ b/sycl/test/on-device/dot_product/dot_product_vec_test.cpp @@ -2,7 +2,7 @@ // For now we only check fallback support because DG1 hardware is not widespread // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/hier_par/hier_par_basic.cpp b/sycl/test/on-device/hier_par/hier_par_basic.cpp index 9b2fbd4be6808..ac6ad75687743 100644 --- a/sycl/test/on-device/hier_par/hier_par_basic.cpp +++ b/sycl/test/on-device/hier_par/hier_par_basic.cpp @@ -7,7 +7,7 @@ //===----------------------------------------------------------------------===// // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/hier_par/hier_par_wgscope.cpp b/sycl/test/on-device/hier_par/hier_par_wgscope.cpp index 4a758f4925788..98e55fa7ffb0f 100644 --- a/sycl/test/on-device/hier_par/hier_par_wgscope.cpp +++ b/sycl/test/on-device/hier_par/hier_par_wgscope.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp b/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp index 46de7bd825803..f497579af48e7 100644 --- a/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp +++ b/sycl/test/on-device/hier_par/hier_par_wgscope_O0.cpp @@ -8,7 +8,7 @@ // RUN: %clangxx -O0 -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_conditional.cpp b/sycl/test/on-device/reduction/reduction_nd_conditional.cpp index 01107b8bc49a7..a2b4940c53a42 100644 --- a/sycl/test/on-device/reduction/reduction_nd_conditional.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_conditional.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp b/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp index 51ab97028c398..235defad000e0 100644 --- a/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_ext_double.cpp @@ -4,7 +4,7 @@ // RUN: %ACC_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports intel::reduce() and barrier() -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // This test performs basic checks of parallel_for(nd_range, reduction, func) // used with 'double' type. diff --git a/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp b/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp index c23dfa5969329..55e91d3b9e445 100644 --- a/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_ext_half.cpp @@ -6,7 +6,7 @@ // RUNx: %ACC_RUN_PLACEHOLDER %t.out // TODO: Enable the test for HOST when it supports intel::reduce() and barrier() -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // This test performs basic checks of parallel_for(nd_range, reduction, func) // used with 'half' type. diff --git a/sycl/test/on-device/reduction/reduction_nd_lambda.cpp b/sycl/test/on-device/reduction/reduction_nd_lambda.cpp index dee12272f75e2..1628b92218e3b 100644 --- a/sycl/test/on-device/reduction/reduction_nd_lambda.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_lambda.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp b/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp index 063d299a3a0cc..24fef3f0eef10 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s0_dw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp b/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp index 5fc7cf39e7a33..af1d3685fa24a 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s0_rw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp b/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp index fc42adc050632..0e553477e6550 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s1_dw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp b/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp index 9748c3569b928..43bd9ac3d05f2 100644 --- a/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp +++ b/sycl/test/on-device/reduction/reduction_nd_s1_rw.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/reduction/reduction_placeholder.cpp b/sycl/test/on-device/reduction/reduction_placeholder.cpp index 231fd2c387891..d948b8cfc3a54 100644 --- a/sycl/test/on-device/reduction/reduction_placeholder.cpp +++ b/sycl/test/on-device/reduction/reduction_placeholder.cpp @@ -3,7 +3,7 @@ // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp b/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp index e62a10af2b468..ef319fcd45df3 100644 --- a/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp +++ b/sycl/test/on-device/reduction/reduction_queue_parallel_for.cpp @@ -3,7 +3,7 @@ // RUN: %ACC_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/reduction/reduction_transparent.cpp b/sycl/test/on-device/reduction/reduction_transparent.cpp index 6c421bf6ae0e2..40347467b47d7 100644 --- a/sycl/test/on-device/reduction/reduction_transparent.cpp +++ b/sycl/test/on-device/reduction/reduction_transparent.cpp @@ -3,7 +3,7 @@ // RUN: %ACC_RUN_PLACEHOLDER %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/reduction/reduction_usm.cpp b/sycl/test/on-device/reduction/reduction_usm.cpp index be32eca07c763..a06c4d83c39a6 100644 --- a/sycl/test/on-device/reduction/reduction_usm.cpp +++ b/sycl/test/on-device/reduction/reduction_usm.cpp @@ -3,7 +3,7 @@ // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out -// RUNx: %HOST_RUN_PLACEHOLDER %t.out +// RUNx: %RUN_ON_HOST %t.out // TODO: Enable the test for HOST when it supports ONEAPI::reduce() and // barrier() diff --git a/sycl/test/on-device/regression/usm_malloc_shared.cpp b/sycl/test/on-device/regression/usm_malloc_shared.cpp index 35122c1a905a3..37c2181712f10 100644 --- a/sycl/test/on-device/regression/usm_malloc_shared.cpp +++ b/sycl/test/on-device/regression/usm_malloc_shared.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // This test checks if users will successfully allocate 160, 0, and -16 bytes of diff --git a/sycl/test/on-device/spec_const/spec_const_hw.cpp b/sycl/test/on-device/spec_const/spec_const_hw.cpp index 0a8d446ece193..3d992766dd377 100644 --- a/sycl/test/on-device/spec_const/spec_const_hw.cpp +++ b/sycl/test/on-device/spec_const/spec_const_hw.cpp @@ -1,7 +1,7 @@ // UNSUPPORTED: cuda // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // diff --git a/sycl/test/on-device/spec_const/spec_const_neg.cpp b/sycl/test/on-device/spec_const/spec_const_neg.cpp index a0f34d19634f7..34d7a3564406b 100644 --- a/sycl/test/on-device/spec_const/spec_const_neg.cpp +++ b/sycl/test/on-device/spec_const/spec_const_neg.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // Specialization constants are not supported on FPGA h/w and emulator. diff --git a/sycl/test/on-device/spec_const/spec_const_redefine.cpp b/sycl/test/on-device/spec_const/spec_const_redefine.cpp index 477e8a40017e0..c64237d4bf3fa 100644 --- a/sycl/test/on-device/spec_const/spec_const_redefine.cpp +++ b/sycl/test/on-device/spec_const/spec_const_redefine.cpp @@ -1,7 +1,7 @@ // UNSUPPORTED: cuda // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER // RUN: env SYCL_PI_TRACE=2 %GPU_RUN_PLACEHOLDER %t.out 2>&1 %GPU_CHECK_PLACEHOLDER // diff --git a/sycl/test/on-device/sub_group/attributes.cpp b/sycl/test/on-device/sub_group/attributes.cpp index 19edacb7a6a5d..0261fe458f24d 100644 --- a/sycl/test/on-device/sub_group/attributes.cpp +++ b/sycl/test/on-device/sub_group/attributes.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUNx: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/barrier.cpp b/sycl/test/on-device/sub_group/barrier.cpp index 5843c56836785..30ddcf3673711 100644 --- a/sycl/test/on-device/sub_group/barrier.cpp +++ b/sycl/test/on-device/sub_group/barrier.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/broadcast.cpp b/sycl/test/on-device/sub_group/broadcast.cpp index 9231a44dcc9c9..0027b32c208b1 100644 --- a/sycl/test/on-device/sub_group/broadcast.cpp +++ b/sycl/test/on-device/sub_group/broadcast.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/broadcast_fp64.cpp b/sycl/test/on-device/sub_group/broadcast_fp64.cpp index 6ab60cac65262..193553afdffaa 100644 --- a/sycl/test/on-device/sub_group/broadcast_fp64.cpp +++ b/sycl/test/on-device/sub_group/broadcast_fp64.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/common.cpp b/sycl/test/on-device/sub_group/common.cpp index 07e3ab5387cb7..4d2c4ac0fc111 100644 --- a/sycl/test/on-device/sub_group/common.cpp +++ b/sycl/test/on-device/sub_group/common.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/generic-shuffle.cpp b/sycl/test/on-device/sub_group/generic-shuffle.cpp index 5017ad0a2b108..90a24d265cfeb 100644 --- a/sycl/test/on-device/sub_group/generic-shuffle.cpp +++ b/sycl/test/on-device/sub_group/generic-shuffle.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/generic_reduce.cpp b/sycl/test/on-device/sub_group/generic_reduce.cpp index 3018f63598052..979b7924eb7db 100644 --- a/sycl/test/on-device/sub_group/generic_reduce.cpp +++ b/sycl/test/on-device/sub_group/generic_reduce.cpp @@ -1,6 +1,6 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -std=c++14 %s -o %t.out // RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple -std=c++14 -D SG_GPU %s -o %t_gpu.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t_gpu.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/info.cpp b/sycl/test/on-device/sub_group/info.cpp index d8602b319ac33..15be9c8392dcc 100644 --- a/sycl/test/on-device/sub_group/info.cpp +++ b/sycl/test/on-device/sub_group/info.cpp @@ -1,7 +1,7 @@ // REQUIRES: opencl // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/load_store.cpp b/sycl/test/on-device/sub_group/load_store.cpp index 8706ea92be021..48096caddd430 100644 --- a/sycl/test/on-device/sub_group/load_store.cpp +++ b/sycl/test/on-device/sub_group/load_store.cpp @@ -6,7 +6,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/reduce.cpp b/sycl/test/on-device/sub_group/reduce.cpp index ecb95c4a3185d..167803e7b31a2 100644 --- a/sycl/test/on-device/sub_group/reduce.cpp +++ b/sycl/test/on-device/sub_group/reduce.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/reduce_fp64.cpp b/sycl/test/on-device/sub_group/reduce_fp64.cpp index 32bd0964b6ad3..33448db127f0c 100644 --- a/sycl/test/on-device/sub_group/reduce_fp64.cpp +++ b/sycl/test/on-device/sub_group/reduce_fp64.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/scan.cpp b/sycl/test/on-device/sub_group/scan.cpp index 1c6ec39c8db56..6af2cfdc175b2 100644 --- a/sycl/test/on-device/sub_group/scan.cpp +++ b/sycl/test/on-device/sub_group/scan.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/scan_fp64.cpp b/sycl/test/on-device/sub_group/scan_fp64.cpp index 8e51f5c6c8642..31a41aa618566 100644 --- a/sycl/test/on-device/sub_group/scan_fp64.cpp +++ b/sycl/test/on-device/sub_group/scan_fp64.cpp @@ -3,7 +3,7 @@ // runtime for every supported ISA // // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/shuffle.cpp b/sycl/test/on-device/sub_group/shuffle.cpp index 13d71be0edce1..ac0a260349751 100644 --- a/sycl/test/on-device/sub_group/shuffle.cpp +++ b/sycl/test/on-device/sub_group/shuffle.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/shuffle_fp64.cpp b/sycl/test/on-device/sub_group/shuffle_fp64.cpp index b0191d910ef38..620858225a8f8 100644 --- a/sycl/test/on-device/sub_group/shuffle_fp64.cpp +++ b/sycl/test/on-device/sub_group/shuffle_fp64.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/on-device/sub_group/vote.cpp b/sycl/test/on-device/sub_group/vote.cpp index df16d59db4c6d..f31aee1701cc6 100644 --- a/sycl/test/on-device/sub_group/vote.cpp +++ b/sycl/test/on-device/sub_group/vote.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %CPU_RUN_PLACEHOLDER %t.out // RUN: %GPU_RUN_PLACEHOLDER %t.out // RUN: %ACC_RUN_PLACEHOLDER %t.out diff --git a/sycl/test/regression/atomic_load.cpp b/sycl/test/regression/atomic_load.cpp index 153ea8c72c717..31b9840616d86 100644 --- a/sycl/test/regression/atomic_load.cpp +++ b/sycl/test/regression/atomic_load.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include using namespace cl::sycl; diff --git a/sycl/test/regression/builtins_vector1.cpp b/sycl/test/regression/builtins_vector1.cpp index a10d31a181c7b..e951ce1c5a8ca 100644 --- a/sycl/test/regression/builtins_vector1.cpp +++ b/sycl/test/regression/builtins_vector1.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/regression/complex_global_object.cpp b/sycl/test/regression/complex_global_object.cpp index adee8f97d90c4..30c0e9ba2375a 100644 --- a/sycl/test/regression/complex_global_object.cpp +++ b/sycl/test/regression/complex_global_object.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // SYCL runtime may construct global objects at function scope. The test ensures // such objects do not cause problems if the first call to SYCL is inside main diff --git a/sycl/test/regression/fp16-with-unnamed-lambda.cpp b/sycl/test/regression/fp16-with-unnamed-lambda.cpp index b4fadf6e79161..91f3f69bdc3bd 100644 --- a/sycl/test/regression/fp16-with-unnamed-lambda.cpp +++ b/sycl/test/regression/fp16-with-unnamed-lambda.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-unnamed-lambda %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include #include diff --git a/sycl/test/regression/global_queue.cpp b/sycl/test/regression/global_queue.cpp index 3e350a13f417a..46381afed5a1b 100644 --- a/sycl/test/regression/global_queue.cpp +++ b/sycl/test/regression/global_queue.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // SYCL dependencies (i.e. low level runtimes) may have global objects of their // own. The test ensures, that those objects do not cause problems. When host diff --git a/sycl/test/regression/group.cpp b/sycl/test/regression/group.cpp index f36423691e89e..d4729ee8cda11 100644 --- a/sycl/test/regression/group.cpp +++ b/sycl/test/regression/group.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==-- group.cpp - Regression tests for cl::sycl::group API bug fixes. -----==// // diff --git a/sycl/test/regression/implicit_atomic_conversion.cpp b/sycl/test/regression/implicit_atomic_conversion.cpp index 7a37747c6dc8f..341791368c420 100644 --- a/sycl/test/regression/implicit_atomic_conversion.cpp +++ b/sycl/test/regression/implicit_atomic_conversion.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/regression/kernel_name_class.cpp b/sycl/test/regression/kernel_name_class.cpp index ebe4edbfc7b6c..65b3fcc3bc659 100644 --- a/sycl/test/regression/kernel_name_class.cpp +++ b/sycl/test/regression/kernel_name_class.cpp @@ -1,7 +1,7 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.ext.out -fsycl-unnamed-lambda -// RUN: %HOST_RUN_PLACEHOLDER %t.out %t.ext.out +// RUN: %RUN_ON_HOST %t.out %t.ext.out //==-- kernel_name_class.cpp - SYCL kernel naming variants test ------------==// // diff --git a/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp b/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp index 3c1dedd814a8f..1411d2041ca77 100644 --- a/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp +++ b/sycl/test/regression/kernel_name_inside_sycl_namespace.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -D__SYCL_DISABLE_NAMESPACE_INLINE__ %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==------- kernel_name_inside_sycl_namespace.cpp - Regression test --------==// // diff --git a/sycl/test/regression/kernel_unnamed.cpp b/sycl/test/regression/kernel_unnamed.cpp index 92b1d794f4e6e..ed6c2202e1376 100644 --- a/sycl/test/regression/kernel_unnamed.cpp +++ b/sycl/test/regression/kernel_unnamed.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -fsycl-unnamed-lambda -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==-- kernel_unnamed.cpp - SYCL kernel naming variants test ------------==// // diff --git a/sycl/test/regression/msvc_crt.cpp b/sycl/test/regression/msvc_crt.cpp index 2219573ba3192..1029be811116f 100644 --- a/sycl/test/regression/msvc_crt.cpp +++ b/sycl/test/regression/msvc_crt.cpp @@ -1,7 +1,7 @@ // RUN: %clang_cl -fsycl /MD -o %t1.exe %s -// RUN: %HOST_RUN_PLACEHOLDER %t1.exe +// RUN: %RUN_ON_HOST %t1.exe // RUN: %clang_cl -fsycl /MDd -o %t2.exe %s -// RUN: %HOST_RUN_PLACEHOLDER %t2.exe +// RUN: %RUN_ON_HOST %t2.exe // REQUIRES: system-windows //==-------------- msvc_crt.cpp - SYCL MSVC CRT test -----------------------==// // diff --git a/sycl/test/regression/private_array_init_test.cpp b/sycl/test/regression/private_array_init_test.cpp index e793c3967ae0c..af4053bebc4cc 100644 --- a/sycl/test/regression/private_array_init_test.cpp +++ b/sycl/test/regression/private_array_init_test.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==- private_array_init_test.cpp - Regression test for private array init -==// // diff --git a/sycl/test/regression/same_unnamed_kernels.cpp b/sycl/test/regression/same_unnamed_kernels.cpp index 8822badec70a5..9a447b56611b1 100644 --- a/sycl/test/regression/same_unnamed_kernels.cpp +++ b/sycl/test/regression/same_unnamed_kernels.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl %s -o %t.out -fsycl-unnamed-lambda -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==----- same_unnamed_kernels.cpp - SYCL kernel naming variants test ------==// // diff --git a/sycl/test/regression/static-buffer-dtor.cpp b/sycl/test/regression/static-buffer-dtor.cpp index 302a238f42b4d..9420f47141e7d 100644 --- a/sycl/test/regression/static-buffer-dtor.cpp +++ b/sycl/test/regression/static-buffer-dtor.cpp @@ -10,7 +10,7 @@ // would start shutting down. //===----------------------------------------------------------------------===// // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out #include diff --git a/sycl/test/regression/sycl-include-gnu11.cpp b/sycl/test/regression/sycl-include-gnu11.cpp index 738029f38f430..c265b0ff25247 100644 --- a/sycl/test/regression/sycl-include-gnu11.cpp +++ b/sycl/test/regression/sycl-include-gnu11.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -std=gnu++11 -fsycl -fsycl-targets=%sycl_triple %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out // UNSUPPORTED: system-windows diff --git a/sycl/test/scheduler/BasicSchedulerTests.cpp b/sycl/test/scheduler/BasicSchedulerTests.cpp index ff3c27cd7c5a0..8be4042d4a726 100644 --- a/sycl/test/scheduler/BasicSchedulerTests.cpp +++ b/sycl/test/scheduler/BasicSchedulerTests.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -I %sycl_source_dir %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==------------------- BasicSchedulerTests.cpp ----------------------------==// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. diff --git a/sycl/test/scheduler/ReleaseResourcesTest.cpp b/sycl/test/scheduler/ReleaseResourcesTest.cpp index 16e9894e701ba..e0651b201d00b 100644 --- a/sycl/test/scheduler/ReleaseResourcesTest.cpp +++ b/sycl/test/scheduler/ReleaseResourcesTest.cpp @@ -1,5 +1,5 @@ // RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -fsycl-dead-args-optimization -I %sycl_source_dir %s -o %t.out -// RUN: %HOST_RUN_PLACEHOLDER %t.out +// RUN: %RUN_ON_HOST %t.out //==------------------- ReleaseResourcesTests.cpp --------------------------==// // From 2ef2919f90845afa3a95fe0b7f79c65cdc778ded Mon Sep 17 00:00:00 2001 From: Vladimir Lazarev Date: Thu, 19 Nov 2020 16:39:17 +0300 Subject: [PATCH 4/4] Restore deleted file --- .../basic_tests/diagnostics/device-check.cpp | 50 +++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 sycl/test/on-device/basic_tests/diagnostics/device-check.cpp diff --git a/sycl/test/on-device/basic_tests/diagnostics/device-check.cpp b/sycl/test/on-device/basic_tests/diagnostics/device-check.cpp new file mode 100644 index 0000000000000..e15854fdc05b3 --- /dev/null +++ b/sycl/test/on-device/basic_tests/diagnostics/device-check.cpp @@ -0,0 +1,50 @@ +// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=cpu %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=gpu %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=acc %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=host %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=CPU %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=GPU %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=ACC %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=HOST %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Cpu %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Gpu %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Acc %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=Host %t.out +// RUN: env SYCL_BE=%sycl_be SYCL_DEVICE_TYPE=XPU %t.out + +//==------------------- device-check.cpp --------------------------==// +// This is a diagnostic test which ensures that +// device types are case-insensitive. +// It also checks for SYCL_DEVICE being set incorrectly. +//==---------------------------------------------------------------==// + +#include +#include + +using namespace cl::sycl; + + +int main() { + try { + queue q = queue(); + auto device = q.get_device(); + auto deviceName = device.get_info(); + std::cout << " Device Name: " << deviceName << std::endl; + } + + catch (runtime_error &E) { + if (std::string(E.what()).find( + "SYCL_DEVICE_TYPE is not recognized. Must be GPU, CPU, ACC or HOST.") == + std::string::npos) { + std::cout << "Test failed: received error is incorrect." << std::endl; + return 1; + } else { + std::cout << "Test passed: caught the expected error." << std::endl; + return 0; + } + } + + std::cout << "Test passed: results are correct." << std::endl; + return 0; +}