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

Commit d948db1

Browse files
committed
Merge remote-tracking branch 'intel_llvm/intel' into simd_view_from_simd
2 parents afdab79 + 6b5ad5c commit d948db1

File tree

132 files changed

+2654
-434
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

132 files changed

+2654
-434
lines changed

SYCL/.clang-format

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
BasedOnStyle: LLVM
2-
CommentPragmas: "(RUN|FAIL|REQUIRES|UNSUPPORTED|CHECK) *:|expected-"
2+
CommentPragmas: "(RUN|FAIL|REQUIRES|UNSUPPORTED|CHECK[A-Za-z0-9_-]*) *:|expected-"

SYCL/AOT/gpu.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@
1010
// UNSUPPORTED: cuda
1111
// CUDA is not compatible with SPIR.
1212
//
13-
// RUN: %clangxx -fsycl -fsycl-targets=spir64_gen -Xsycl-target-backend=spir64_gen "-device *" %S/Inputs/aot.cpp -o %t.out
13+
// RUN: %clangxx -fsycl -fsycl-targets=spir64_gen -Xsycl-target-backend=spir64_gen %gpu_aot_target_opts %S/Inputs/aot.cpp -o %t.out
1414
// RUN: %GPU_RUN_PLACEHOLDER %t.out

SYCL/AOT/multiple-devices.cpp

Lines changed: 15 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -6,72 +6,54 @@
66
//
77
//===----------------------------------------------------------------------===//
88

9-
// REQUIRES: opencl-aot, ocloc, aoc, cpu, gpu, accelerator, llvm-link, llvm-spirv
9+
// REQUIRES: opencl-aot, ocloc, aoc, cpu, gpu, accelerator
1010
// UNSUPPORTED: cuda
1111
// CUDA is not compatible with SPIR.
1212

13-
// 1-command compilation case
14-
// Targeting CPU, GPU, FPGA
15-
// RUN: %clangxx -fsycl -fsycl-targets=spir64_x86_64,spir64_gen,spir64_fpga -Xsycl-target-backend=spir64_gen "-device *" %S/Inputs/aot.cpp -o %t_all.out
16-
// RUN: %HOST_RUN_PLACEHOLDER %t_all.out
17-
// RUN: %CPU_RUN_PLACEHOLDER %t_all.out
18-
// RUN: %GPU_RUN_PLACEHOLDER %t_all.out
19-
// RUN: %ACC_RUN_PLACEHOLDER %t_all.out
13+
// Produce a fat object for all targets (generic SPIR-V, CPU, GPU, FPGA)
14+
// RUN: %clangxx -fsycl -fsycl-targets=spir64,spir64_x86_64,spir64_gen,spir64_fpga %S/Inputs/aot.cpp -c -o %t.o
2015

21-
// FIXME: Change the behavior when proper automation for assert support is
22-
// introduced. For the time being, AOT flow can't detect if specific extension
23-
// is available for this or that device. The automation to be introduced is to
24-
// query native binary generator on specific features.
25-
//
26-
// Produce object file, spirv, device images to combine these differently
27-
// at link-time, thus testing various AOT-compiled images configurations
28-
// RUN: %clangxx -fsycl %S/Inputs/aot.cpp -c -o %t.o
29-
// RUN: %clangxx -fsycl -fsycl-link-targets=spir64 %t.o -o %t.spv
30-
// AOT-compile device binary images
31-
// Neither of AOT tools can compile several files, hence, here is this
32-
// workaround
33-
// RUN: %llvm_spirv -r %sycl_libs_dir/libsycl-fallback-cassert.spv -o=%T/fallback-cassert.bc
34-
// RUN: %llvm_spirv -r %t.spv -o=%t.bc
35-
// RUN: %llvm_link %t.bc %T/fallback-cassert.bc -o=%t2.bc
36-
// RUN: %llvm_spirv %t2.bc -o=%t.spv
37-
// RUN: opencl-aot %t.spv -o=%t_cpu.ir --device=cpu
38-
// RUN: ocloc -file %t.spv -spirv_input -output %t_gen.out -output_no_suffix -device cfl
39-
// RUN: aoc %t.spv -o %t_fpga.aocx -sycl -dep-files=%t.d
16+
// CPU, GPU, FPGA
17+
// RUN: %clangxx -fsycl -fsycl-targets=spir64_x86_64,spir64_gen,spir64_fpga -Xsycl-target-backend=spir64_gen %gpu_aot_target_opts %t.o -o %t_all_aot.out
18+
// RUN: %HOST_RUN_PLACEHOLDER %t_all_aot.out
19+
// RUN: %CPU_RUN_PLACEHOLDER %t_all_aot.out
20+
// RUN: %GPU_RUN_PLACEHOLDER %t_all_aot.out
21+
// RUN: %ACC_RUN_PLACEHOLDER %t_all_aot.out
4022

4123
// CPU, GPU
42-
// RUN: %clangxx -fsycl -fsycl-add-targets=spir64_x86_64:%t_cpu.ir,spir64_gen:%t_gen.out %t.o -o %t_cpu_gpu.out
24+
// RUN: %clangxx -fsycl -fsycl-targets=spir64_x86_64,spir64_gen -Xsycl-target-backend=spir64_gen %gpu_aot_target_opts %t.o -o %t_cpu_gpu.out
4325
// RUN: %HOST_RUN_PLACEHOLDER %t_cpu_gpu.out
4426
// RUN: %CPU_RUN_PLACEHOLDER %t_cpu_gpu.out
4527
// RUN: %GPU_RUN_PLACEHOLDER %t_cpu_gpu.out
4628

4729
// CPU, FPGA
48-
// RUN: %clangxx -fsycl -fsycl-add-targets=spir64_x86_64:%t_cpu.ir,spir64_fpga:%t_fpga.aocx %t.o -o %t_cpu_fpga.out
30+
// RUN: %clangxx -fsycl -fsycl-targets=spir64_x86_64,spir64_fpga %t.o -o %t_cpu_fpga.out
4931
// RUN: %HOST_RUN_PLACEHOLDER %t_cpu_fpga.out
5032
// RUN: %CPU_RUN_PLACEHOLDER %t_cpu_fpga.out
5133
// RUN: %ACC_RUN_PLACEHOLDER %t_cpu_fpga.out
5234

5335
// GPU, FPGA
54-
// RUN: %clangxx -fsycl -fsycl-add-targets=spir64_gen:%t_gen.out,spir64_fpga:%t_fpga.aocx %t.o -o %t_gpu_fpga.out
36+
// RUN: %clangxx -fsycl -fsycl-targets=spir64_gen,spir64_fpga -Xsycl-target-backend=spir64_gen %gpu_aot_target_opts %t.o -o %t_gpu_fpga.out
5537
// RUN: %HOST_RUN_PLACEHOLDER %t_gpu_fpga.out
5638
// RUN: %GPU_RUN_PLACEHOLDER %t_gpu_fpga.out
5739
// RUN: %ACC_RUN_PLACEHOLDER %t_gpu_fpga.out
5840

5941
// No AOT-compiled image for CPU
60-
// RUN: %clangxx -fsycl -fsycl-add-targets=spir64:%t.spv,spir64_gen:%t_gen.out,spir64_fpga:%t_fpga.aocx %t.o -o %t_spv_gpu_fpga.out
42+
// RUN: %clangxx -fsycl -fsycl-targets=spir64,spir64_gen,spir64_fpga -Xsycl-target-backend=spir64_gen %gpu_aot_target_opts %t.o -o %t_spv_gpu_fpga.out
6143
// RUN: %CPU_RUN_PLACEHOLDER %t_spv_gpu_fpga.out
6244
// Check that execution on AOT-compatible devices is unaffected
6345
// RUN: %GPU_RUN_PLACEHOLDER %t_spv_gpu_fpga.out
6446
// RUN: %ACC_RUN_PLACEHOLDER %t_spv_gpu_fpga.out
6547

6648
// No AOT-compiled image for GPU
67-
// RUN: %clangxx -fsycl -fsycl-add-targets=spir64:%t.spv,spir64_x86_64:%t_cpu.ir,spir64_fpga:%t_fpga.aocx %t.o -o %t_spv_cpu_fpga.out
49+
// RUN: %clangxx -fsycl -fsycl-targets=spir64,spir64_x86_64,spir64_fpga %t.o -o %t_spv_cpu_fpga.out
6850
// RUN: %GPU_RUN_PLACEHOLDER %t_spv_cpu_fpga.out
6951
// Check that execution on AOT-compatible devices is unaffected
7052
// RUN: %CPU_RUN_PLACEHOLDER %t_spv_cpu_fpga.out
7153
// RUN: %ACC_RUN_PLACEHOLDER %t_spv_cpu_fpga.out
7254

7355
// No AOT-compiled image for FPGA
74-
// RUN: %clangxx -fsycl -fsycl-add-targets=spir64:%t.spv,spir64_x86_64:%t_cpu.ir,spir64_gen:%t_gen.out %t.o -o %t_spv_cpu_gpu.out
56+
// RUN: %clangxx -fsycl -fsycl-targets=spir64,spir64_x86_64,spir64_gen -Xsycl-target-backend=spir64_gen %gpu_aot_target_opts %t.o -o %t_spv_cpu_gpu.out
7557
// RUN: %ACC_RUN_PLACEHOLDER %t_spv_cpu_gpu.out
7658
// Check that execution on AOT-compatible devices is unaffected
7759
// RUN: %CPU_RUN_PLACEHOLDER %t_spv_cpu_gpu.out

SYCL/Assert/assert_in_kernels.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,17 @@
66
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
77
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
88
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
10-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
10+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
11+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1112
//
1213
// CHECK-NOT: One shouldn't see this message
1314
// CHECK: {{.*}}assert_in_kernels.hpp:26: void kernelFunc2(int *, int): global id: [{{[0,2]}},0,0], local id: [0,0,0]
1415
// CHECK-SAME: Assertion `Buf[wiID] == 0 && "from assert statement"` failed.
1516
// CHECK-NOT: test aborts earlier, one shouldn't see this message
1617
// CHECK-NOT: The test ended.
18+
//
19+
// CHECK-ACC-NOT: {{.*}}assert_in_kernels.hpp:26: void kernelFunc2(int *, int): global id: [{{[0,2]}},0,0], local id: [0,0,0]
20+
// CHECK-ACC: The test ended.
1721

1822
#include "assert_in_kernels.hpp"

SYCL/Assert/assert_in_kernels_win.cpp

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,23 @@
11
// REQUIRES: windows
2+
// UNSUPPORTED: cuda || hip
23
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
34
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
45
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
56
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
67
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
8-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
8+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
9+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
10+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
911
//
1012
// CHECK-NOT: One shouldn't see this message
11-
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
13+
// FIXME Windows version prints '(null)' instead of '<unknown func>' once in a
1214
// while for some insane reason.
1315
// CHECK: {{.*}}assert_in_kernels.hpp:26: {{<unknown func>|(null)}}: global id: [{{[0,2]}},0,0], local id: [0,0,0]
1416
// CHECK-SAME: Assertion `Buf[wiID] == 0 && "from assert statement"` failed.
1517
// CHECK-NOT: test aborts earlier, one shouldn't see this message
1618
// CHECK-NOT: The test ended.
19+
//
20+
// CHECK-ACC-NOT: {{.*}}assert_in_kernels.hpp:26: {{<unknown func>|(null)}}: global id: [{{[0,2]}},0,0], local id: [0,0,0]
21+
// CHECK-ACC: The test ended.
1722

1823
#include "assert_in_kernels.hpp"

SYCL/Assert/assert_in_multiple_tus.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,16 @@
66
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
77
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
88
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
10-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
10+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
11+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1112
//
1213
// CHECK: {{.*}}kernels_in_file2.cpp:15: int calculus(int): global id: [5,0,0], local id: [1,0,0]
1314
// CHECK-SAME: Assertion `X && "this message from calculus"` failed.
1415
// CHECK-NOT: this message from file2
1516
// CHECK-NOT: The test ended.
17+
//
18+
// CHECK-ACC-NOT: {{.*}}kernels_in_file2.cpp:15: int calculus(int): global id: [5,0,0], local id: [1,0,0]
19+
// CHECK-ACC: The test ended.
1620

1721
#include "assert_in_multiple_tus.hpp"

SYCL/Assert/assert_in_multiple_tus_one_ndebug.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,15 @@
66
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
77
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
88
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
10-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
10+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
11+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1112
//
1213
// CHECK-NOT: this message from calculus
1314
// CHECK: {{.*}}assert_in_multiple_tus.hpp:20: int checkFunction(): global id: [5,0,0],
1415
// CHECK-SAME: local id: [1,0,0] Assertion `X && "Nil in result"` failed.
1516
// CHECK-NOT: this message from file2
1617
// CHECK-NOT: The test ended.
18+
//
19+
// CHECK-ACC-NOT: {{.*}}assert_in_multiple_tus.hpp:20: int checkFunction(): global id: [5,0,0],
20+
// CHECK-ACC: The test ended.
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,21 @@
11
// REQUIRES: windows
2+
// UNSUPPORTED: cuda || hip
23
// 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
34
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
45
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
56
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
67
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
8+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
79
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
8-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
10+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
911
//
1012
// CHECK-NOT: this message from calculus
11-
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
13+
// FIXME Windows version prints '(null)' instead of '<unknown func>' once in a
1214
// while for some insane reason.
1315
// CHECK: {{.*}}assert_in_multiple_tus.hpp:20: {{<unknown func>|(null)}}: global id: [5,0,0],
1416
// CHECK-SAME: local id: [1,0,0] Assertion `X && "Nil in result"` failed.
1517
// CHECK-NOT: this message from file2
1618
// CHECK-NOT: The test ended.
19+
//
20+
// CHECK-ACC-NOT: {{.*}}assert_in_multiple_tus.hpp:20: {{<unknown func>|(null)}}: global id: [5,0,0],
21+
// CHECK-ACC: The test ended.
Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,22 @@
11
// REQUIRES: windows
2+
// UNSUPPORTED: cuda || hip
23
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out
34
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
45
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
56
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
67
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
8-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
8+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
9+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
10+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
911
//
10-
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
12+
// FIXME Windows version prints '(null)' instead of '<unknown func>' once in a
1113
// while for some insane reason.
1214
// CHECK: {{.*}}kernels_in_file2.cpp:15: {{<unknown func>|(null)}}: global id: [5,0,0], local id: [1,0,0]
1315
// CHECK-SAME: Assertion `X && "this message from calculus"` failed.
1416
// CHECK-NOT: this message from file2
1517
// CHECK-NOT: The test ended.
18+
//
19+
// CHECK-ACC-NOT: {{.*}}kernels_in_file2.cpp:15: {{<unknown func>|(null)}}: global id: [5,0,0], local id: [1,0,0]
20+
// CHECK-ACC: The test ended.
1621

1722
#include "assert_in_multiple_tus.hpp"

SYCL/Assert/assert_in_one_kernel.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,15 @@
66
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
77
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
88
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
10-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
9+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
10+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
11+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1112
//
1213
// CHECK: {{.*}}assert_in_one_kernel.hpp:10: void kernelFunc(int *, int): global id: [{{[0-3]}},0,0], local id: [0,0,0]
1314
// CHECK-SAME: Assertion `Buf[wiID] != 0 && "from assert statement"` failed.
1415
// CHECK-NOT: The test ended.
16+
//
17+
// CHECK-ACC-NOT: {{.*}}assert_in_one_kernel.hpp:10: void kernelFunc(int *, int): global id: [{{[0-3]}},0,0], local id: [0,0,0]
18+
// CHECK-ACC: The test ended.
1519

1620
#include "assert_in_one_kernel.hpp"
Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,21 @@
11
// REQUIRES: windows
2+
// UNSUPPORTED: cuda || hip
23
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
34
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
45
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
56
// RUN: %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
67
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
7-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
8-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
8+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
9+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
10+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
911
//
10-
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
12+
// FIXME Windows version prints '(null)' instead of '<unknown func>' once in a
1113
// while for some insane reason.
1214
// CHECK: {{.*}}assert_in_one_kernel.hpp:10: {{<unknown func>|(null)}}: global id: [{{[0-3]}},0,0], local id: [0,0,0]
1315
// CHECK-SAME: Assertion `Buf[wiID] != 0 && "from assert statement"` failed.
1416
// CHECK-NOT: The test ended.
17+
//
18+
// CHECK-ACC-NOT: {{.*}}assert_in_one_kernel.hpp:10: {{<unknown func>|(null)}}: global id: [{{[0-3]}},0,0], local id: [0,0,0]
19+
// CHECK-ACC: The test ended.
1520

1621
#include "assert_in_one_kernel.hpp"

SYCL/Assert/assert_in_simultaneous_kernels.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,15 @@
1212
// release yet.
1313
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
1414
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
15-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
16-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
15+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
16+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
17+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1718
//
1819
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:12: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
1920
// CHECK-SAME: Assertion `false && "from assert statement"` failed.
2021
// CHECK-NOT: The test ended.
22+
//
23+
// CHECK-ACC-NOT: {{.*}}assert_in_simultaneous_kernels.hpp:12: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
24+
// CHECK-ACC: The test ended.
2125

2226
#include "assert_in_simultaneous_kernels.hpp"

SYCL/Assert/assert_in_simultaneous_kernels_win.cpp

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
// REQUIRES: windows
2+
// UNSUPPORTED: cuda || hip
23
// RUN: %clangxx -DSYCL_ENABLE_FALLBACK_ASSERT -fsycl -fsycl-targets=%sycl_triple %s -o %t.out %threads_lib
34
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
45
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
@@ -10,13 +11,17 @@
1011
// release yet.
1112
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
1213
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
13-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
14-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
14+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
15+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
16+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1517
//
16-
// FIXME Windows versionprints '(null)' instead of '<unknown func>' once in a
18+
// FIXME Windows version prints '(null)' instead of '<unknown func>' once in a
1719
// while for some insane reason.
1820
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:12: {{<unknown func>|(null)}}: global id: [9,7,0], local id: [0,0,0]
1921
// CHECK-SAME: Assertion `false && "from assert statement"` failed.
2022
// CHECK-NOT: The test ended.
23+
//
24+
// CHECK-ACC-NOT: {{.*}}assert_in_simultaneous_kernels.hpp:12: {{<unknown func>|(null)}}: global id: [9,7,0], local id: [0,0,0]
25+
// CHECK-ACC: The test ended.
2126

2227
#include "assert_in_simultaneous_kernels.hpp"

SYCL/Assert/assert_in_simultaneously_multiple_tus.cpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,15 @@
1111
// release yet.
1212
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
1313
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
14-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
15-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
14+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
15+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
16+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1617
//
1718
// CHECK: {{this message from file1|this message from file2}}
1819
// CHECK-NOT: The test ended.
20+
//
21+
// CHECK-ACC-NOT: {{this message from file1|this message from file2}}
22+
// CHECK-ACC: The test ended.
1923

2024
#include "Inputs/kernels_in_file2.hpp"
2125
#include <CL/sycl.hpp>

SYCL/Assert/assert_in_simultaneously_multiple_tus_one_ndebug.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,12 @@
1111
// release yet.
1212
// RUN: env SYCL_PI_LEVEL_ZERO_TRACK_INDIRECT_ACCESS_MEMORY=1 %GPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
1313
// RUN: %GPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
14-
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt || true
15-
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
14+
// Shouldn't fail on ACC as fallback assert isn't enqueued there
15+
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
16+
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1617
//
1718
// CHECK: this message from file1
1819
// CHECK-NOT: this message from file2
1920
// CHECK-NOT: The test ended.
21+
//
22+
// CHECK-ACC: The test ended.

0 commit comments

Comments
 (0)