Skip to content

Commit 0bcc826

Browse files
anmyachevalexbaden
authored andcommitted
[Windows] Fix level_zero/ze_api.h not found when running UT by using LEVEL_ZERO_V1_SDK_PATH env var (#3656)
@pbchekin @vlad-penkin I took all the artifacts after using (on local machine) the sdk installer (all options by default), packed the folder into a tar archive and changed the name of the environment variable. It seems that this is all that is needed for integration. **UPD**: although `ZE_PATH` is not a standard and documented variable in level_zero (at least I haven't found it), it was decided to leave it in so as not to break the code of users who might use it. Interestingly, I haven't found any use of it in the PyTorch code. --------- Signed-off-by: Anatoly Myachev <[email protected]> (cherry picked from commit 9304351)
1 parent e3985ff commit 0bcc826

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

.github/workflows/build-test-windows.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ permissions: read-all
2222
env:
2323
PYTHONIOENCODING: utf-8
2424
NEW_WORKSPACE: C:\gh${{ github.run_id }}
25-
ZE_PATH: C:\level_zero
2625
SKIPLIST: --skip-list scripts/skiplist/${{ inputs.skip_list }}
2726
TRITON_TEST_CMD: bash -x scripts/test-triton.sh --skip-pytorch-install --skip-pip-install --skip-list scripts/skiplist/${{ inputs.skip_list }} --reports-dir reports --ignore-errors
2827

.github/workflows/pip-test-windows.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ permissions: read-all
3434
env:
3535
PYTHONIOENCODING: utf-8
3636
NEW_WORKSPACE: C:\gh${{ github.run_id }}
37-
ZE_PATH: C:\level_zero
3837
PYTEST_MAX_PROCESSES: 8
3938
SKIPLIST: --skip-list scripts/skiplist/${{ inputs.skip_list || 'a770' }}
4039
TRITON_TEST_CMD: bash -x scripts/test-triton.sh --skip-pytorch-install --skip-pip-install --skip-list scripts/skiplist/${{ inputs.skip_list || 'a770' }} --reports-dir reports --ignore-errors

third_party/intel/backend/driver.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,9 @@ def inject_pytorch_dep(self):
100100

101101
@cached_property
102102
def _compute_compilation_options_lazy(self):
103-
ze_root = os.getenv("ZE_PATH", default="/usr/local")
103+
ze_root = os.getenv("LEVEL_ZERO_V1_SDK_PATH")
104+
if ze_root is None:
105+
ze_root = os.getenv("ZE_PATH", default="/usr/local")
104106
include_dir = [os.path.join(ze_root, "include")]
105107

106108
library_dir = []

0 commit comments

Comments
 (0)