Skip to content

Commit

Permalink
[SYCL] Run the LIT tests using the selected backend (intel#1288)
Browse files Browse the repository at this point in the history
  • Loading branch information
fwyzard committed Mar 14, 2020
2 parents 42d6108 + f856948 commit c29131e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions sycl/test/lit.cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,8 @@
print("Adding path to opencl-aot tool to PATH")
os.environ['PATH'] = os.path.pathsep.join((os.getenv('PATH'), config.sycl_tools_dir))

backend=lit_config.params.get('SYCL_BE', "PI_OPENCL")
backend = lit_config.params.get('SYCL_BE', "PI_OPENCL")
config.environment['SYCL_BE'] = backend

get_device_count_by_type_path = os.path.join(config.llvm_tools_dir, "get_device_count_by_type")

Expand Down Expand Up @@ -157,8 +158,6 @@ def getDeviceCount(device_type):
if platform.system() == "Linux":
gpu_run_on_linux_substitute = "env SYCL_DEVICE_TYPE=GPU "
gpu_check_on_linux_substitute = "| FileCheck %s"
if cuda:
gpu_run_on_linux_substitute += " SYCL_BE=PI_CUDA "

config.substitutions.append( ('%GPU_RUN_PLACEHOLDER', gpu_run_substitute) )
config.substitutions.append( ('%GPU_RUN_ON_LINUX_PLACEHOLDER', gpu_run_on_linux_substitute) )
Expand Down

0 comments on commit c29131e

Please sign in to comment.