Skip to content

Commit 4c3db62

Browse files
author
Hugh Delaney
authored
[SYCL] Remove all uses of _be suffix in testing (#13226)
The `_be` suffix was used in sycl/test to identify support for lots of different backends. For instance: `hip_be`, `cuda_be` etc. sycl/test-e2e used the same backend identifiers but without the `_be` suffix. This has caused some confusion, allowing tests to be added to sycl/test that do not use the `_be` suffix, meaning they are considered UNSUPPORTED for all backends. This patch removes all uses of the `_be` suffix in sycl/test, so that the backend support is aligned with the keywords used in sycl/test-e2e. Some tests that were not running for any backends now fail, so they are marked XFAIL.
1 parent 4f91bbb commit 4c3db62

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+59
-54
lines changed

sycl/test/abi/pi_cuda_symbol_check.dump

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
# RUN: env LLVM_BIN_PATH=%llvm_build_bin_dir %python %sycl_tools_src_dir/abi_check.py --mode check_symbols --reference %s %sycl_libs_dir/libpi_cuda.so
77
# REQUIRES: linux
8-
# REQUIRES: cuda_be
8+
# REQUIRES: cuda
99
# UNSUPPORTED: libcxx
1010

1111
piContextCreate

sycl/test/abi/pi_hip_symbol_check.dump

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
# RUN: env LLVM_BIN_PATH=%llvm_build_bin_dir %python %sycl_tools_src_dir/abi_check.py --mode check_symbols --reference %s %sycl_libs_dir/libpi_hip.so
77
# REQUIRES: linux
8-
# REQUIRES: hip_be
8+
# REQUIRES: hip
99
# UNSUPPORTED: libcxx
1010

1111
piContextCreate

sycl/test/abi/pi_nativecpu_symbol_check.dump

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
# RUN: env LLVM_BIN_PATH=%llvm_build_bin_dir %python %sycl_tools_src_dir/abi_check.py --mode check_symbols --reference %s %sycl_libs_dir/libpi_native_cpu.so
77
# REQUIRES: linux
8-
# REQUIRES: native_cpu_be
8+
# REQUIRES: native_cpu
99
# UNSUPPORTED: libcxx
1010

1111
piContextCreate

sycl/test/basic_tests/interop-backend-traits-cuda.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: cuda_be
1+
// REQUIRES: cuda
22
// RUN: %clangxx -fsycl -fsyntax-only %s
33
// RUN: %clangxx -fsycl -fsyntax-only -DUSE_CUDA_EXPERIMENTAL %s
44

sycl/test/basic_tests/interop-backend-traits-hip.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: hip_be
1+
// REQUIRES: hip
22
// RUN: %clangxx -fsycl -fsyntax-only %s
33

44
#include <sycl/sycl.hpp>

sycl/test/basic_tests/interop-backend-traits-level-zero.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: level_zero_be
1+
// REQUIRES: level_zero
22
// RUN: %clangxx %fsycl-host-only -fsyntax-only %s
33

44
#include <sycl/sycl.hpp>

sycl/test/basic_tests/interop-backend-traits-opencl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: opencl_be
1+
// REQUIRES: opencl
22
// RUN: %clangxx -fsycl -fsyntax-only %s
33

44
#include <CL/cl.h>

sycl/test/basic_tests/interop-hip.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: hip_be
1+
// REQUIRES: hip
22
// RUN: %clangxx %fsycl-host-only -fsyntax-only -Xclang -verify -Xclang -verify-ignore-unexpected=note %s
33
// RUN: %clangxx %fsycl-host-only -fsyntax-only -Xclang -verify -Xclang -verify-ignore-unexpected=note -D__SYCL_INTERNAL_API %s
44

sycl/test/check_device_code/hip/matrix/compile-query-hip-gfx90a.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: hip
2+
23
// RUN: %clangxx -fsycl -fsycl-targets=amd_gpu_gfx90a %s -o compile-query-hip
34

45
#include <iostream>

sycl/test/check_device_code/hip/matrix/matrix-hip-bfloat16-float-test.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: hip
2+
// XFAIL: hip
23

34
// RUN: %clangxx -fsycl-device-only -fsycl-targets=amd_gpu_gfx90a -S -Xclang -emit-llvm %s -o -| FileCheck %s
45

sycl/test/check_device_code/hip/matrix/matrix-hip-double-double-test.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: hip
2+
// XFAIL: hip
23

34
// RUN: %clangxx -fsycl-device-only -fsycl-targets=amd_gpu_gfx90a -S -Xclang -emit-llvm %s -o -| FileCheck %s
45

sycl/test/check_device_code/hip/matrix/matrix-hip-half-float-test.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: hip
2+
// XFAIL: hip
23

34
// RUN: %clangxx -fsycl-device-only -fsycl-targets=amd_gpu_gfx90a -S -Xclang -emit-llvm %s -o -| FileCheck %s
45

sycl/test/check_device_code/hip/matrix/matrix-hip-int8-int32-test.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: hip
2+
// XFAIL: hip
23

34
// RUN: %clangxx -fsycl-device-only -fsycl-targets=amd_gpu_gfx90a -S -Xclang -emit-llvm %s -o -| FileCheck %s
45

sycl/test/extensions/macro_cuda.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// This test checks presence of macros for available extensions.
22
// RUN: %clangxx -fsycl -fsyntax-only %s
3-
// REQUIRES: cuda_be
3+
// REQUIRES: cuda
44

55
#include <sycl/sycl.hpp>
66

sycl/test/extensions/macro_hip.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// This test checks presence of macros for available extensions.
22
// RUN: %clangxx -fsycl -fsyntax-only %s
3-
// REQUIRES: hip_be
3+
// REQUIRES: hip
44

55
#include <sycl/sycl.hpp>
66

sycl/test/lit.cfg.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -144,20 +144,20 @@
144144

145145
additional_flags = config.sycl_clang_extra_flags.split(" ")
146146

147-
if config.cuda_be == "ON":
148-
config.available_features.add("cuda_be")
147+
if config.cuda == "ON":
148+
config.available_features.add("cuda")
149149

150-
if config.hip_be == "ON":
151-
config.available_features.add("hip_be")
150+
if config.hip == "ON":
151+
config.available_features.add("hip")
152152

153-
if config.opencl_be == "ON":
154-
config.available_features.add("opencl_be")
153+
if config.opencl == "ON":
154+
config.available_features.add("opencl")
155155

156-
if config.level_zero_be == "ON":
157-
config.available_features.add("level_zero_be")
156+
if config.level_zero == "ON":
157+
config.available_features.add("level_zero")
158158

159-
if config.native_cpu_be == "ON":
160-
config.available_features.add("native_cpu_be")
159+
if config.native_cpu == "ON":
160+
config.available_features.add("native_cpu")
161161

162162
if config.native_cpu_ock == "ON":
163163
config.available_features.add("native_cpu_ock")

sycl/test/lit.site.cfg.py.in

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ config.llvm_enable_projects = "@LLVM_ENABLE_PROJECTS@"
2626
config.sycl_threads_lib = '@SYCL_THREADS_LIB@'
2727
config.sycl_use_libcxx = '@SYCL_USE_LIBCXX@'
2828
config.extra_environment = lit_config.params.get("extra_environment", "@LIT_EXTRA_ENVIRONMENT@")
29-
config.cuda_be = '@SYCL_BUILD_PI_CUDA@'
30-
config.hip_be = '@SYCL_BUILD_PI_HIP@'
31-
config.opencl_be = '@SYCL_BUILD_PI_OPENCL@'
32-
config.level_zero_be = '@SYCL_BUILD_PI_LEVEL_ZERO@'
33-
config.native_cpu_be = '@SYCL_BUILD_NATIVE_CPU@'
29+
config.cuda = '@SYCL_BUILD_PI_CUDA@'
30+
config.hip = '@SYCL_BUILD_PI_HIP@'
31+
config.opencl = '@SYCL_BUILD_PI_OPENCL@'
32+
config.level_zero = '@SYCL_BUILD_PI_LEVEL_ZERO@'
33+
config.native_cpu = '@SYCL_BUILD_NATIVE_CPU@'
3434
config.native_cpu_ock = '@NATIVECPU_USE_OCK@'
3535
config.sycl_preview_lib_enabled = '@SYCL_ENABLE_MAJOR_RELEASE_PREVIEW_LIB@'
3636

sycl/test/native_cpu/atomic-base.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Simple test that checks that we can run a simple applications that uses
22
// builtins
3-
// REQUIRES: native_cpu_be
3+
// REQUIRES: native_cpu
44
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
55
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
66
#include <sycl/sycl.hpp>

sycl/test/native_cpu/call_host_func.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44
// This test is needed since we need to make sure that there no

sycl/test/native_cpu/check-pi-output.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env SYCL_PI_TRACE=1 ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t | FileCheck %s
44

sycl/test/native_cpu/driver-fsycl.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/example-sycl-application.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/global-id-range.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/globaloffsetchecks.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44

sycl/test/native_cpu/link-noinline.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -fno-inline -O0 %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/local-id-range.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/local_basic.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44
#include <sycl/sycl.hpp>

sycl/test/native_cpu/multi-devices-swap.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// REQUIRES: native_cpu_be
2-
// REQUIRES: opencl_be
1+
// REQUIRES: native_cpu
2+
// REQUIRES: opencl
33
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu,spir64 %s -o %t
44
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
55

sycl/test/native_cpu/multi-devices.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// REQUIRES: native_cpu_be
2-
// REQUIRES: opencl_be
1+
// REQUIRES: native_cpu
2+
// REQUIRES: opencl
33
// RUN: %clangxx -fsycl -fsycl-targets=spir64,native_cpu %s -o %t
44
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
55

sycl/test/native_cpu/multiple_tu.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
//RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -c -o %t_main.o
33
//RUN: %clangxx -fsycl -fsycl-targets=native_cpu %S/Inputs/init.cpp -c -o %t_init.o
44
//RUN: %clangxx -fsycl -fsycl-targets=native_cpu %S/Inputs/plusone.cpp -c -o %t_plusone.o

sycl/test/native_cpu/no-dead-arg.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -O1 -fsycl-dead-args-optimization %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/no-opt.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -g -O0 -o %t %s
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" SYCL_DEVICE_ALLOWLIST="BackendName:native_cpu" %t

sycl/test/native_cpu/no_kernels.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/native_cpu/readwrite_rectops.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44

sycl/test/native_cpu/scalar_args.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44
#include <sycl/sycl.hpp>

sycl/test/native_cpu/sycl-external-static.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// Check that kernel can call a SYCL_EXTERNAL function defined in a
33
// static library.
44
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -DSOURCE1 %s -c -o %t1.o

sycl/test/native_cpu/sycl-external.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Test1 - check that kernel can call a SYCL_EXTERNAL function defined in a
22
// different object file.
3-
// REQUIRES: native_cpu_be
3+
// REQUIRES: native_cpu
44
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -DSOURCE1 %s -c -o %t1.o
55
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -DSOURCE2 %s -c -o %t2.o
66
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %t1.o %t2.o -o %t

sycl/test/native_cpu/unnamed.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44
#include <sycl/sycl.hpp>

sycl/test/native_cpu/unused-regression.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44
#include <sycl/sycl.hpp>

sycl/test/native_cpu/user-defined-private-type.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44
#include <functional>

sycl/test/native_cpu/user-defined-type.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44
#include <functional>

sycl/test/native_cpu/usm_basic.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR=native_cpu:cpu %t
44
#include <sycl/sycl.hpp>

sycl/test/native_cpu/vector-add.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: native_cpu_be
1+
// REQUIRES: native_cpu
22
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu %s -o %t
33
// RUN: env ONEAPI_DEVICE_SELECTOR="native_cpu:cpu" %t
44

sycl/test/regression/multi_targeting.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// REQUIRES: cuda || hip_be
1+
// REQUIRES: cuda || hip
22
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple,spir64 %s -o -
33
// RUN: %clangxx -fsycl -fsycl-targets=spir64,%sycl_triple %s -o -
44
//

0 commit comments

Comments
 (0)