Skip to content

Commit 5f96f3f

Browse files
authored
[SYCL][CUDA][E2E] Disable tests failing on CUDA 13 (#22508)
After enabling CUDA 13 workflow (see #21564) few tests are failing sporadically: - WorkGroupMemory/basic_usage.cpp - bindless_images/read_sampled.cpp - bindless_images/vulkan_interop/vulkan_sycl_image_interop_read_1d.cpp - bindless_images/vulkan_interop/vulkan_sycl_image_interop_write_1d_unsampled.cpp This PR implements CUDA version detection in LIT configuration and conditionally disables these 4 tests on CUDA 13+. Tracked in: - #21806 - #21807 - #21808
1 parent 6fc5c4b commit 5f96f3f

5 files changed

Lines changed: 36 additions & 0 deletions

File tree

sycl/test-e2e/WorkGroupMemory/basic_usage.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
// UNSUPPORTED: hip
22
// UNSUPPORTED-TRACKER: https://github.com/intel/llvm/issues/17339
3+
4+
// UNSUPPORTED: cuda-ge-13
5+
// UNSUPPORTED-TRACKER: https://github.com/intel/llvm/issues/21806
6+
37
// RUN: %{build} -o %t.out
48
// RUN: %{run} %t.out
59
// XFAIL: spirv-backend

sycl/test-e2e/bindless_images/read_sampled.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
// UNSUPPORTED: hip
44
// UNSUPPORTED-INTENDED: Returning non-FP values from sampling fails on HIP.
55

6+
// UNSUPPORTED: cuda-ge-13
7+
// UNSUPPORTED-TRACKER: https://github.com/intel/llvm/issues/21807
8+
69
// RUN: %{build} -o %t.out
710
// RUN: %{run} %t.out
811

sycl/test-e2e/bindless_images/vulkan_interop/vulkan_sycl_image_interop_read_1d.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
// REQUIRES: aspect-ext_oneapi_external_memory_import || (windows && level_zero && aspect-ext_oneapi_bindless_images)
33
// REQUIRES: vulkan
44

5+
// UNSUPPORTED: cuda-ge-13
6+
// UNSUPPORTED-TRACKER: https://github.com/intel/llvm/issues/21808
7+
58
// RUN: %{build} %link-vulkan -o %t.out %if target-spir %{ -Wno-ignored-attributes %}
69

710
/*

sycl/test-e2e/bindless_images/vulkan_interop/vulkan_sycl_image_interop_write_1d_unsampled.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
// UNSUPPORTED: windows
77
// UNSUPPORTED-TRACKER: CMPLRLLVM-73525
88

9+
// UNSUPPORTED: cuda-ge-13
10+
// UNSUPPORTED-TRACKER: https://github.com/intel/llvm/issues/21808
11+
912
// RUN: %{build} %link-vulkan -o %t.out %if target-spir %{ -Wno-ignored-attributes %}
1013

1114
/*

sycl/test-e2e/lit.cfg.py

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
import textwrap
99
import shlex
1010
import shutil
11+
import json
1112

1213
import lit.formats
1314
import lit.util
@@ -824,6 +825,28 @@ def remove_level_zero_suffix(devices):
824825
config.cuda_libs_dir = os.path.join(os.environ["CUDA_PATH"], r"lib64")
825826
config.cuda_include = os.path.join(os.environ["CUDA_PATH"], "include")
826827

828+
# Detect CUDA version and add version-specific features for conditional test execution
829+
cuda_version_json = os.path.join(os.environ["CUDA_PATH"], "version.json")
830+
if os.path.exists(cuda_version_json):
831+
try:
832+
with open(cuda_version_json, "r") as f:
833+
version_data = json.load(f)
834+
cuda_version_str = version_data.get("cuda", {}).get("version", "")
835+
if cuda_version_str:
836+
major = int(cuda_version_str.split(".")[0])
837+
MIN_CUDA_VERSION = 11 # Minimum CUDA version supported by SYCL
838+
839+
for version in range(MIN_CUDA_VERSION, major + 1):
840+
config.available_features.add(f"cuda-ge-{version}")
841+
842+
lit_config.note(
843+
f"CUDA {cuda_version_str}: added features cuda-ge-{MIN_CUDA_VERSION}..cuda-ge-{major}"
844+
)
845+
except (json.JSONDecodeError, IOError, ValueError, KeyError) as e:
846+
lit_config.warning(
847+
f"Failed to parse CUDA version from {cuda_version_json}: {e}"
848+
)
849+
827850
config.substitutions.append(("%threads_lib", config.sycl_threads_lib))
828851

829852
if lit_config.params.get("ze_debug"):

0 commit comments

Comments
 (0)