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

Commit 76ab40d

Browse files
[SYCL][ESIMD][EMU] Set default platform for ESIMD_EMULATOR (#1226)
* [SYCL][ESIMD][EMU] Setting default platform for ESIMD_EMULATOR - CM_EMU library package is recently updated to support multiple targets. This fix is to avoid target platform setting failure
1 parent 3654a30 commit 76ab40d

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

SYCL/lit.cfg.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,13 @@
348348
if lit_config.params.get('ze_debug'):
349349
gpu_run_substitute = " env ZE_DEBUG={ZE_DEBUG} SYCL_DEVICE_FILTER=level_zero:gpu ".format(ZE_DEBUG=config.ze_debug)
350350
config.available_features.add('ze_debug'+config.ze_debug)
351+
elif config.sycl_be == "ext_intel_esimd_emulator":
352+
# ESIMD_EMULATOR backend uses CM_EMU library package for
353+
# multi-threaded execution on CPU, and the package emulates
354+
# multiple target platforms. In case user does not specify
355+
# what target platform to emulate, 'skl' is chosen by default.
356+
if not "CM_RT_PLATFORM" in os.environ:
357+
gpu_run_substitute += "CM_RT_PLATFORM=skl "
351358

352359
if platform.system() == "Linux":
353360
gpu_run_on_linux_substitute = "env SYCL_DEVICE_FILTER={SYCL_PLUGIN}:gpu ".format(SYCL_PLUGIN=config.sycl_be)

0 commit comments

Comments
 (0)