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

[SYCL] Enable tests outside Unix environment (part 1) #475

Open
wants to merge 6 commits into
base: intel
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_kernels.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,9 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK-NOT: One shouldn't see this message
// CHECK: {{.*}}assert_in_kernels.hpp:26: void kernelFunc2(int *, int): global id: [{{[0,2]}},0,0], local id: [0,0,0]
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_multiple_tus.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,9 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK: {{.*}}kernels_in_file2.cpp:15: int calculus(int): global id: [5,0,0], local id: [1,0,0]
// CHECK-SAME: Assertion `X && "this message from calculus"` failed.
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_multiple_tus_one_ndebug.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,9 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -DDEFINE_NDEBUG_INFILE2 -I %S/Inputs %S/assert_in_multiple_tus.cpp %S/Inputs/kernels_in_file2.cpp -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK-NOT: this message from calculus
// CHECK: {{.*}}assert_in_multiple_tus.hpp:20: int checkFunction(): global id: [5,0,0],
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_multiple_tus_one_ndebug_win.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
// REQUIRES: windows
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -DDEFINE_NDEBUG_INFILE2 -I %S/Inputs %S/assert_in_multiple_tus.cpp %S/Inputs/kernels_in_file2.cpp -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK-NOT: this message from calculus
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_multiple_tus_win.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
// REQUIRES: windows
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
// while for some insane reason.
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_one_kernel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,9 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK: {{.*}}assert_in_one_kernel.hpp:10: void kernelFunc(int *, int): global id: [{{[0-3]}},0,0], local id: [0,0,0]
// CHECK-SAME: Assertion `Buf[wiID] != 0 && "from assert statement"` failed.
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_one_kernel_win.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
// REQUIRES: windows
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
// while for some insane reason.
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_simultaneous_kernels.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,15 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out %threads_lib
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
//
// Since this is a multi-threaded application enable memory tracking and
// deferred release feature in the Level Zero plugin to avoid releasing memory
// too early. This is necessary because currently SYCL RT sets indirect access
// flag for all kernels and the Level Zero runtime doesn't support deferred
// release yet.
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:12: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
// CHECK-SAME: Assertion `false && "from assert statement"` failed.
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_simultaneous_kernels_win.cpp
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
// REQUIRES: windows
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out %threads_lib
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
//
// Since this is a multi-threaded application enable memory tracking and
// deferred release feature in the Level Zero plugin to avoid releasing memory
// too early. This is necessary because currently SYCL RT sets indirect access
// flag for all kernels and the Level Zero runtime doesn't support deferred
// release yet.
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
// while for some insane reason.
Expand Down
9 changes: 3 additions & 6 deletions SYCL/Assert/assert_in_simultaneously_multiple_tus.cpp
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out %threads_lib
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
//
// Since this is a multi-threaded application enable memory tracking and
// deferred release feature in the Level Zero plugin to avoid releasing memory
// too early. This is necessary because currently SYCL RT sets indirect access
// flag for all kernels and the Level Zero runtime doesn't support deferred
// release yet.
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK: {{this message from file1|this message from file2}}
// CHECK-NOT: The test ended.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,15 @@
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
// UNSUPPORTED: cuda || hip
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -DDEFINE_NDEBUG_INFILE2 -I %S/Inputs %S/assert_in_simultaneously_multiple_tus.cpp %S/Inputs/kernels_in_file2.cpp -o %t.out %threads_lib
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
//
// Since this is a multi-threaded application enable memory tracking and
// deferred release feature in the Level Zero plugin to avoid releasing memory
// too early. This is necessary because currently SYCL RT sets indirect access
// flag for all kernels and the Level Zero runtime doesn't support deferred
// release yet.
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// CHECK: this message from file1
// CHECK-NOT: this message from file2
Expand Down
2 changes: 1 addition & 1 deletion SYCL/Basic/buffer/native_buffer_creation_flags.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER SYCL_PI_TRACE=-1 %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=-1 %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER

#include <CL/sycl.hpp>

Expand Down
6 changes: 3 additions & 3 deletions SYCL/Basic/enqueue_barrier.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
// RUN: env SYCL_PI_TRACE=2 %GPU_RUN_PLACEHOLDER %t.out 2>&1 %GPU_CHECK_PLACEHOLDER
// RUN: env SYCL_PI_TRACE=2 %ACC_RUN_PLACEHOLDER %t.out 2>&1 %ACC_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER

// The test is failing sporadically on Windows OpenCL RTs
// Disabling on windows until fixed
Expand Down
2 changes: 1 addition & 1 deletion SYCL/Basic/event_release.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// RUN: %clangxx -fsycl %s -o %t.out
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
#include <CL/sycl.hpp>
#include <cassert>
#include <iostream>
Expand Down
6 changes: 3 additions & 3 deletions SYCL/Basic/host-task-dependency.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out %threads_lib
// RUN: %CPU_RUN_PLACEHOLDER SYCL_PI_TRACE=-1 %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER SYCL_PI_TRACE=-1 %t.out 2>&1 %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER SYCL_PI_TRACE=-1 %t.out 2>&1 %ACC_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=-1 %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=-1 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER env SYCL_PI_TRACE=-1 %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
//
// TODO: Behaviour is unstable for level zero on Windows. Enable when fixed.
// TODO: The test is sporadically fails on CUDA. Enable when fixed.
Expand Down
6 changes: 3 additions & 3 deletions SYCL/Basic/info_ocl_version.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %HOST_RUN_PLACEHOLDER %t.out
// RUN: env %CPU_RUN_PLACEHOLDER %t.out
// RUN: env %GPU_RUN_PLACEHOLDER %t.out
// RUN: env %ACC_RUN_PLACEHOLDER %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

//==--------info_ocl_version.cpp - SYCL objects get_info() test ------------==//
//
Expand Down
2 changes: 1 addition & 1 deletion SYCL/Basic/kernel_bundle/kernel_bundle_api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// involved leads to multiple definition of AssertHappened structure due each
// device image is statically linked against fallback libdevice.
// RUN: %clangxx -DSYCL_DISABLE_FALLBACK_ASSERT=1 -fsycl -fsycl-device-code-split=per_kernel -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %CPU_CHECK_PLACEHOLDER
//
// -fsycl-device-code-split is not supported for cuda
// UNSUPPORTED: cuda || hip
Expand Down
2 changes: 1 addition & 1 deletion SYCL/Basic/parallel_for_range_roundup.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: env SYCL_PARALLEL_FOR_RANGE_ROUNDING_TRACE=1 %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PARALLEL_FOR_RANGE_ROUNDING_TRACE=1 %t.out %GPU_CHECK_PLACEHOLDER

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My guess is that one can imply xxx_RUN_PLACE contains env (or other OS-dependent stuff) already. Should env be present on the RUN command in such a case, then?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

env is LIT builtin command, as well as echo. And echo can't run env.


#include <CL/sycl.hpp>

Expand Down
6 changes: 3 additions & 3 deletions SYCL/Basic/queue/release.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: env SYCL_PI_TRACE=2 %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
// RUN: env SYCL_PI_TRACE=2 %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %GPU_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %CPU_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %ACC_CHECK_PLACEHOLDER
//
// XFAIL: hip_nvidia

Expand Down
2 changes: 1 addition & 1 deletion SYCL/Basic/use_pinned_host_memory.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER

#include <CL/sycl.hpp>

Expand Down
13 changes: 12 additions & 1 deletion SYCL/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,17 @@ endif()
find_package(Threads REQUIRED)
set(SYCL_THREADS_LIB ${CMAKE_THREAD_LIBS_INIT})

find_package(Python3 COMPONENTS Interpreter REQUIRED)

if (NOT TEST_SUITE_LIT)
message(FATAL_ERROR "LIT was not found, specify TEST_SUITE_LIT")
endif()

find_program(FILECHECK FileCheck)
if (NOT FILECHECK)
message(FATAL_ERROR "FileCheck utility was not found in PATH")
endif()

configure_file("${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.py.in" "${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg")

if(CHECK_SYCL_ALL)
Expand All @@ -20,7 +31,7 @@ if(CHECK_SYCL_ALL)
string(REPLACE "," "_" TARGET check-sycl-${TARGET_BE}-${TARGET_DEVICES})

add_custom_target(${TARGET}
COMMAND python3 ${TEST_SUITE_LIT} ${TEST_SUITE_LIT_FLAGS} --param sycl_be=${TARGET_BE} --param target_devices=${TARGET_DEVICES} .
COMMAND ${Python3_EXECUTABLE} ${TEST_SUITE_LIT} ${TEST_SUITE_LIT_FLAGS} --param sycl_be=${TARGET_BE} --param target_devices=${TARGET_DEVICES} .
COMMENT "Running the SYCL tests for ${TARGET} backend"
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
DEPENDS ${TEST_SUITE_TARGETS}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
// program builds at run-time
// RUN: %clangxx -DSYCL_DISABLE_FALLBACK_ASSERT -D__SYCL_INTERNAL_API -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %HOST_RUN_PLACEHOLDER %t.out
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
// RUN: env SYCL_PI_TRACE=2 %GPU_RUN_PLACEHOLDER %t.out 2>&1 %GPU_CHECK_PLACEHOLDER
// RUN: %CPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
// RUN: %GPU_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
//
//==----------- spec_const_redefine.cpp ------------------------------------==//
//
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@
// XFAIL: opencl && accelerator
// UNSUPPORTED: cuda || level_zero
#include "spec_const_redefine_accelerator.cpp"
// RUN: env SYCL_PI_TRACE=2 %ACC_RUN_PLACEHOLDER %t.out 2>&1 %ACC_CHECK_PLACEHOLDER
// RUN: %ACC_RUN_PLACEHOLDER env SYCL_PI_TRACE=2 %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
Loading