From 2c85e99742b29f171c9c183267ae78f5ecaf3fa2 Mon Sep 17 00:00:00 2001 From: Udit Agarwal <16324601+uditagarwal97@users.noreply.github.com> Date: Tue, 6 Feb 2024 07:37:46 -0800 Subject: [PATCH] [SYCL] Update test scripts and sycl-ls to use 'fpga' with ONEAPI_DEVICE_SELECTOR (#12596) As per the ONEAPI_DEVICE_SELECTOR [documentation](https://github.com/intel/llvm/blob/sycl/sycl/doc/EnvironmentVariables.md#oneapi_device_selector), the device type can only be cpu, gpu, or fpga (or any combination of those). Currently, 'acc' is also accepted by ONEAPI_DEVICE_SELECTOR as a valid device type, which is incorrect. This PR modifies lit.cfg.py and sycl-ls to use 'fpga' instead of 'acc' in ONEAPI_DEVICE_SELECTOR. --- sycl/test-e2e/lit.cfg.py | 2 +- sycl/tools/sycl-ls/sycl-ls.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sycl/test-e2e/lit.cfg.py b/sycl/test-e2e/lit.cfg.py index e1b2b4a1ef28d..a25f775edc9e1 100644 --- a/sycl/test-e2e/lit.cfg.py +++ b/sycl/test-e2e/lit.cfg.py @@ -427,7 +427,7 @@ config.sycl_devices = [x.replace("ext_oneapi_", "") for x in config.sycl_devices] available_devices = { - "opencl": ("cpu", "gpu", "acc"), + "opencl": ("cpu", "gpu", "fpga"), "cuda": "gpu", "level_zero": "gpu", "hip": "gpu", diff --git a/sycl/tools/sycl-ls/sycl-ls.cpp b/sycl/tools/sycl-ls/sycl-ls.cpp index 39bced0c1c9d1..ef2ea8fd2f121 100644 --- a/sycl/tools/sycl-ls/sycl-ls.cpp +++ b/sycl/tools/sycl-ls/sycl-ls.cpp @@ -49,7 +49,7 @@ std::string getDeviceTypeName(const device &Device) { case info::device_type::host: return "host"; case info::device_type::accelerator: - return "acc"; + return "fpga"; default: return "unknown"; }