Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

Commit 23c261c

Browse files
authored
[SYCL] Enable Basic/alloc_pinned_host_memory for CUDA devices (#149)
1 parent 36e7560 commit 23c261c

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

SYCL/Basic/alloc_pinned_host_memory.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
// REQUIRES: level_zero
1+
// REQUIRES: level_zero || cuda
22

33
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t2.out
4-
// RUN: env SYCL_PI_TRACE=2 ZE_DEBUG=1 %GPU_RUN_PLACEHOLDER %t2.out 2>&1 %GPU_CHECK_PLACEHOLDER
4+
// RUN: env SYCL_PI_TRACE=2 ZE_DEBUG=1 %GPU_RUN_PLACEHOLDER %t2.out 2>&1 %GPU_L0_CHECK_PLACEHOLDER
55
// RUN: %HOST_RUN_PLACEHOLDER %t2.out
66
// RUN: %CPU_RUN_PLACEHOLDER %t2.out
77
// RUN: %GPU_RUN_PLACEHOLDER %t2.out

SYCL/lit.cfg.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,7 @@
214214
gpu_run_substitute = "true"
215215
gpu_run_on_linux_substitute = "true "
216216
gpu_check_substitute = ""
217+
gpu_l0_check_substitute = ""
217218
gpu_check_on_linux_substitute = ""
218219

219220
if 'gpu' in config.target_devices.split(','):
@@ -223,6 +224,9 @@
223224
gpu_check_substitute = "| FileCheck %s"
224225
config.available_features.add('gpu')
225226

227+
if config.sycl_be == "level_zero":
228+
gpu_l0_check_substitute = "| FileCheck %s"
229+
226230
if platform.system() == "Linux":
227231
gpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:gpu ".format(SYCL_PLUGIN=config.sycl_be)
228232
gpu_check_on_linux_substitute = "| FileCheck %s"
@@ -233,6 +237,7 @@
233237
config.substitutions.append( ('%GPU_RUN_PLACEHOLDER', gpu_run_substitute) )
234238
config.substitutions.append( ('%GPU_RUN_ON_LINUX_PLACEHOLDER', gpu_run_on_linux_substitute) )
235239
config.substitutions.append( ('%GPU_CHECK_PLACEHOLDER', gpu_check_substitute) )
240+
config.substitutions.append( ('%GPU_L0_CHECK_PLACEHOLDER', gpu_l0_check_substitute) )
236241
config.substitutions.append( ('%GPU_CHECK_ON_LINUX_PLACEHOLDER', gpu_check_on_linux_substitute) )
237242

238243
acc_run_substitute = "true"

0 commit comments

Comments
 (0)