Skip to content

Commit 8c34359

Browse files
[SYCL] Fix multi_lib_app test to accommodate build/run diffs on Windows CI. (#20195)
Windows CI sometimes builds on one machine and runs on another, and the paths might differ. Fixing test to account for this. Issue: #20023
1 parent b762423 commit 8c34359

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

sycl/test-e2e/IntermediateLib/multi_lib_app.cpp

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
// UNSUPPORTED: cuda || hip
22
// UNSUPPORTED-TRACKER: CMPLRLLVM-69415
33

4-
// UNSUPPORTED: windows
5-
// UNSUPPORTED-TRACKER: https://github.com/intel/llvm/issues/20023
6-
74
// DEFINE: %{fPIC_flag} = %if windows %{%} %else %{-fPIC%}
85
// DEFINE: %{shared_lib_ext} = %if windows %{dll%} %else %{so%}
96

@@ -17,12 +14,17 @@
1714
// So the hack here is to put heredoc in the definition
1815
// and use single quotes, which Python forgivingly accepts.
1916
// clang-format on
17+
18+
// On Windows, the CI sometimes builds on one machine and runs on another.
19+
// This means that %T might not be consistent between build and run.
20+
// So we use %{run-aux} to perform ALL actions on the run machine
21+
// like we do for the AoT tests.
2022

21-
// RUN: %{build} %{fPIC_flag} -DSO_PATH='R"(%T)"' -o %t.out
23+
// RUN: %{run-aux} %clangxx -fsycl %{fPIC_flag} -DSO_PATH='R"(%T)"' -o %t.out %s
2224

23-
// RUN: %clangxx -fsycl %{fPIC_flag} -shared -DINC=1 -o %T/lib_a.%{shared_lib_ext} %S/Inputs/incrementing_lib.cpp
24-
// RUN: %clangxx -fsycl %{fPIC_flag} -shared -DINC=2 -o %T/lib_b.%{shared_lib_ext} %S/Inputs/incrementing_lib.cpp
25-
// RUN: %clangxx -fsycl %{fPIC_flag} -shared -DINC=4 -o %T/lib_c.%{shared_lib_ext} %S/Inputs/incrementing_lib.cpp
25+
// RUN: %{run-aux} %clangxx -fsycl %{fPIC_flag} -shared -DINC=1 -o %T/lib_a.%{shared_lib_ext} %S/Inputs/incrementing_lib.cpp
26+
// RUN: %{run-aux} %clangxx -fsycl %{fPIC_flag} -shared -DINC=2 -o %T/lib_b.%{shared_lib_ext} %S/Inputs/incrementing_lib.cpp
27+
// RUN: %{run-aux} %clangxx -fsycl %{fPIC_flag} -shared -DINC=4 -o %T/lib_c.%{shared_lib_ext} %S/Inputs/incrementing_lib.cpp
2628

2729
// RUN: env UR_L0_LEAKS_DEBUG=1 %{run} %t.out
2830

0 commit comments

Comments
 (0)