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

Commit ef9c80e

Browse files
author
Alexander Batashev
committed
fix assertions tests
1 parent 6a053ff commit ef9c80e

11 files changed

+33
-33
lines changed

SYCL/Assert/assert_in_kernels.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// FIXME unsuppoerted on CUDA until fallback libdevice becomes available
33
// UNSUPPORTED: cuda
44
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
5-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
6-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
5+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
6+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
7+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
88
//
99
// CHECK-NOT: One shouldn't see this message
1010
// CHECK: {{.*}}assert_in_kernels.hpp:26: void kernelFunc2(int *, int): global id: [{{[0,2]}},0,0], local id: [0,0,0]

SYCL/Assert/assert_in_multiple_tus.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// FIXME unsuppoerted on CUDA until fallback libdevice becomes available
33
// UNSUPPORTED: cuda
44
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out
5-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
6-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
5+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
6+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
7+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
88
//
99
// CHECK: {{.*}}kernels_in_file2.cpp:15: int calculus(int): global id: [5,0,0], local id: [1,0,0]
1010
// CHECK-SAME: Assertion `X && "this message from calculus"` failed.

SYCL/Assert/assert_in_multiple_tus_one_ndebug.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// FIXME unsuppoerted on CUDA until fallback libdevice becomes available
33
// UNSUPPORTED: cuda
44
// RUN: %clangxx -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
5-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
6-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
5+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
6+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
7+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
88
//
99
// CHECK-NOT: this message from calculus
1010
// CHECK: {{.*}}assert_in_multiple_tus.hpp:20: int checkFunction(): global id: [5,0,0],

SYCL/Assert/assert_in_multiple_tus_one_ndebug_win.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// REQUIRES: windows
22
// RUN: %clangxx -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
3-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
4-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
5-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
3+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
4+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
5+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
66
//
77
// CHECK-NOT: this message from calculus
88
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a

SYCL/Assert/assert_in_multiple_tus_win.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// REQUIRES: windows
22
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out
3-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
4-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
5-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
3+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
4+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
5+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
66
//
77
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
88
// while for some insane reason.

SYCL/Assert/assert_in_one_kernel.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// FIXME unsuppoerted on CUDA until fallback libdevice becomes available
33
// UNSUPPORTED: cuda
44
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
5-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
6-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
5+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
6+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
7+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
88
//
99
// CHECK: {{.*}}assert_in_one_kernel.hpp:10: void kernelFunc(int *, int): global id: [{{[0-3]}},0,0], local id: [0,0,0]
1010
// CHECK-SAME: Assertion `Buf[wiID] != 0 && "from assert statement"` failed.

SYCL/Assert/assert_in_one_kernel_win.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// REQUIRES: windows
22
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
3-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
4-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
5-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
3+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
4+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
5+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
66
//
77
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
88
// while for some insane reason.

SYCL/Assert/assert_in_simultaneous_kernels.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
// FIXME unsuppoerted on CUDA until fallback libdevice becomes available
33
// UNSUPPORTED: cuda
44
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out %threads_lib
5-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
6-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
5+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
6+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
7+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
88
//
99
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:12: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
1010
// CHECK-SAME: Assertion `false && "from assert statement"` failed.

SYCL/Assert/assert_in_simultaneous_kernels_win.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// REQUIRES: windows
22
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out %threads_lib
3-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
4-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
5-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
3+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
4+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
5+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
66
//
77
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
88
// while for some insane reason.

SYCL/Assert/assert_in_simultaneously_multiple_tus.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
// with this configuration once it's debugged.
66
// UNSUPPORTED: linux && opencl && fpga
77
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out %threads_lib
8-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
9-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
10-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
8+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
9+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
10+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
1111
//
1212
// CHECK: {{this message from file1|this message from file2}}
1313
// CHECK-NOT: The test ended.

SYCL/Assert/assert_in_simultaneously_multiple_tus_one_ndebug.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
// with this configuration once it's debugged.
66
// UNSUPPORTED: linux && opencl && fpga
77
// RUN: %clangxx -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
8-
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
9-
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER
10-
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_CHECK_PLACEHOLDER
8+
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_ERR_REDIRECT %CPU_CHECK_PLACEHOLDER
9+
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_ERR_REDIRECT %GPU_CHECK_PLACEHOLDER
10+
// RUN: %ACC_RUN_PLACEHOLDER %t.out %ACC_ERR_REDIRECT %ACC_CHECK_PLACEHOLDER
1111
//
1212
// CHECK: this message from file1
1313
// CHECK-NOT: this message from file2

0 commit comments

Comments
 (0)