Skip to content

Commit 3a54abc

Browse files
committed
[SYCL] change substitution instead of compiler flags
1 parent b97a472 commit 3a54abc

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

sycl/test-e2e/DeviceLib/separate_compile_test.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@
1010
// RUN: %clangxx -fsycl -fsycl-link %S/std_complex_math_fp64_test.cpp -o %t_fp64_device.o %{mathflags}
1111
// RUN: %clangxx -fsycl-device-only -Xclang -fsycl-int-header=std_complex_math_fp64_test_ihdr.h %S/std_complex_math_fp64_test.cpp -Wno-sycl-strict %{mathflags}
1212
// >> host compilation...
13-
// RUN: %clangxx -Wno-error=unused-command-line-argument -isystem %sycl_include -Wno-error=ignored-attributes %cxx_std_optionc++17 %include_option std_complex_math_fp64_test_ihdr.h -c %S/std_complex_math_fp64_test.cpp -o %t_fp64_host.o %sycl_options -Wno-sycl-strict %{mathflags}
13+
// RUN: %clangxx -Wno-error=unused-command-line-argument %sycl_include -Wno-error=ignored-attributes %cxx_std_optionc++17 %include_option std_complex_math_fp64_test_ihdr.h -c %S/std_complex_math_fp64_test.cpp -o %t_fp64_host.o %sycl_options -Wno-sycl-strict %{mathflags}
1414
// RUN: %clangxx %t_fp64_host.o %t_fp64_device.o -Wno-unused-command-line-argument -o %t_fp64.out %sycl_options %{mathflags}
1515
// RUN: %{run} %t.out

sycl/test-e2e/SeparateCompile/test.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,13 @@
88
// >> device compilation...
99
// RUN: %clangxx -DSYCL_DISABLE_FALLBACK_ASSERT -fno-sycl-dead-args-optimization -fsycl-device-only -Xclang -fsycl-int-header=sycl_ihdr_a.h %s -o a_kernel.bc -Wno-sycl-strict
1010
// >> host compilation...
11-
// RUN: %if !windows %{ %clangxx -Wno-error=ignored-attributes -isystem %sycl_include -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT %cxx_std_optionc++17 %include_option sycl_ihdr_a.h %debug_option -c %s -o a.o %sycl_options -fno-sycl-dead-args-optimization -Wno-sycl-strict %}
12-
// RUN: %if windows %{ %clangxx -Wno-error=ignored-attributes /imsvc %sycl_include -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT %cxx_std_optionc++17 %include_option sycl_ihdr_a.h %debug_option -c %s -o a.o %sycl_options -fno-sycl-dead-args-optimization -Wno-sycl-strict %}
11+
// RUN: %clangxx -Wno-error=ignored-attributes %sycl_include -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT %cxx_std_optionc++17 %include_option sycl_ihdr_a.h %debug_option -c %s -o a.o %sycl_options -fno-sycl-dead-args-optimization -Wno-sycl-strict
1312
//
1413
// >> ---- compile src2
1514
// >> device compilation...
1615
// RUN: %clangxx -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT -DB_CPP=1 -fno-sycl-dead-args-optimization -fsycl-device-only -Xclang -fsycl-int-header=sycl_ihdr_b.h %s -o b_kernel.bc -Wno-sycl-strict
1716
// >> host compilation...
18-
// RUN: %if !windows %{ %clangxx -Wno-error=ignored-attributes -isystem %sycl_include -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT -DB_CPP=1 %cxx_std_optionc++17 %include_option sycl_ihdr_b.h %debug_option -c %s -o b.o %sycl_options -fno-sycl-dead-args-optimization -Wno-sycl-strict %}
19-
// RUN: %if windows %{ %clangxx -Wno-error=ignored-attributes /imsvc %sycl_include -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT -DB_CPP=1 %cxx_std_optionc++17 %include_option sycl_ihdr_b.h %debug_option -c %s -o b.o %sycl_options -fno-sycl-dead-args-optimization -Wno-sycl-strict %}
17+
// RUN: %clangxx -Wno-error=ignored-attributes %sycl_include -Wno-error=unused-command-line-argument -DSYCL_DISABLE_FALLBACK_ASSERT -DB_CPP=1 %cxx_std_optionc++17 %include_option sycl_ihdr_b.h %debug_option -c %s -o b.o %sycl_options -fno-sycl-dead-args-optimization -Wno-sycl-strict
2018
//
2119
// >> ---- bundle .o with .spv
2220
// >> run bundler

sycl/test-e2e/lit.cfg.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,10 +151,11 @@
151151
("%sycl_static_libs_dir", config.sycl_libs_dir + "/../lib")
152152
)
153153
config.substitutions.append(("%obj_ext", ".obj"))
154+
config.substitutions.append(("/imsvc %sycl_include", config.sycl_include))
154155
elif platform.system() == "Linux":
155156
config.substitutions.append(("%sycl_static_libs_dir", config.sycl_libs_dir))
156157
config.substitutions.append(("%obj_ext", ".o"))
157-
config.substitutions.append(("%sycl_include", config.sycl_include))
158+
config.substitutions.append(("-isystem %sycl_include", config.sycl_include))
158159

159160
# Intel GPU FAMILY availability
160161
if lit_config.params.get("gpu-intel-gen11", False):

0 commit comments

Comments
 (0)