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

Commit 86176da

Browse files
committed
Merge branch 'intel' into math_marray_tests
2 parents 499c642 + 258a40d commit 86176da

File tree

225 files changed

+6126
-1257
lines changed

Some content is hidden

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

225 files changed

+6126
-1257
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1-
* @vladimirlaz @romanovvlad @bader
1+
* @pvchupin
22

33
# Use runtime team as the umbrella for most of the tests
44
/SYCL/ @intel/llvm-reviewers-runtime
55

6-
76
# SYCL sub-directory matchers are grouped by code owner first, followed by
87
# alphabetical order within the group. Please, keep this ordering.
98

.github/workflows/clang-format.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ jobs:
2020
- name: Run clang-format for the patch
2121
shell: bash {0}
2222
run: |
23+
git config --global --add safe.directory /__w/llvm-test-suite/llvm-test-suite
2324
git clang-format ${GITHUB_SHA}^1
2425
git diff > ./clang-format.patch
2526

SYCL/Assert/assert_in_kernels_ndebug.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
2-
// UNSUPPORTED: cuda || hip
1+
// FIXME unsupported on HIP until fallback libdevice becomes available
2+
// UNSUPPORTED: hip
33
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple -DNDEBUG %S/assert_in_kernels.cpp -o %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out %CPU_CHECK_PLACEHOLDER
55
// RUN: %GPU_RUN_PLACEHOLDER %t.out %GPU_CHECK_PLACEHOLDER

SYCL/Assert/assert_in_simultaneous_kernels.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@
1616
// RUN: %ACC_RUN_PLACEHOLDER %t.out &> %t.txt
1717
// RUN: %ACC_RUN_PLACEHOLDER FileCheck %s --check-prefix=CHECK-ACC --input-file %t.txt
1818
//
19-
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:12: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
19+
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:13: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
2020
// CHECK-SAME: Assertion `false && "from assert statement"` failed.
2121
// CHECK-NOT: The test ended.
2222
//
23-
// CHECK-ACC-NOT: {{.*}}assert_in_simultaneous_kernels.hpp:12: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
23+
// CHECK-ACC-NOT: {{.*}}assert_in_simultaneous_kernels.hpp:13: void assertFunc(): global id: [9,7,0], local id: [0,0,0]
2424
// CHECK-ACC: The test ended.
2525

2626
#include "assert_in_simultaneous_kernels.hpp"

SYCL/Assert/assert_in_simultaneous_kernels.hpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#include <CL/sycl.hpp>
22
#include <cassert>
3+
#include <cstdio>
34
#include <iostream>
45
#include <thread>
56

@@ -44,6 +45,15 @@ void runTestForTid(queue *Q, size_t Tid) {
4445
}
4546

4647
int main(int Argc, const char *Argv[]) {
48+
// On windows stderr output becomes messed up if several thread
49+
// output simultaneously. Hence, setting explicit line buffering here.
50+
#ifndef __SYCL_DEVICE_ONLY__
51+
if (setvbuf(stderr, nullptr, _IOLBF, BUFSIZ)) {
52+
std::cerr << "Can't set line-buffering mode fo stderr\n";
53+
return 1;
54+
}
55+
#endif
56+
4757
std::vector<std::thread> threadPool;
4858
threadPool.reserve(NUM_THREADS);
4959

SYCL/Assert/assert_in_simultaneous_kernels_win.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@
1717
//
1818
// FIXME Windows version prints '(null)' instead of '<unknown func>' once in a
1919
// while for some insane reason.
20-
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:12: {{<unknown func>|(null)}}: global id: [9,7,0], local id: [0,0,0]
20+
// CHECK: {{.*}}assert_in_simultaneous_kernels.hpp:13: {{<unknown func>|(null)}}: global id: [9,7,0], local id: [0,0,0]
2121
// CHECK-SAME: Assertion `false && "from assert statement"` failed.
2222
// CHECK-NOT: The test ended.
2323
//
24-
// CHECK-ACC-NOT: {{.*}}assert_in_simultaneous_kernels.hpp:12: {{<unknown func>|(null)}}: global id: [9,7,0], local id: [0,0,0]
24+
// CHECK-ACC-NOT: {{.*}}assert_in_simultaneous_kernels.hpp:13: {{<unknown func>|(null)}}: global id: [9,7,0], local id: [0,0,0]
2525
// CHECK-ACC: The test ended.
2626

2727
#include "assert_in_simultaneous_kernels.hpp"

SYCL/Assert/assert_in_simultaneously_multiple_tus.cpp

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
// FIXME unsupported on CUDA and HIP until fallback libdevice becomes available
2-
// UNSUPPORTED: cuda || hip
3-
// clang-format off
4-
// Failed on Linux on unrelated change (FileCheck error: '.../assert_in_simultaneously_multiple_tus.cpp.tmp.txt' is empty)
5-
// clang-format on
6-
// REQUIRES: TEMPORARILY_DISABLED
2+
// FIXME flaky output on Level Zero
3+
// UNSUPPORTED: cuda || hip || level_zero
74
// RUN: %clangxx -DSYCL_FALLBACK_ASSERT=1 -fsycl -fsycl-targets=%sycl_triple -I %S/Inputs %s %S/Inputs/kernels_in_file2.cpp -o %t.out %threads_lib
85
// RUN: %CPU_RUN_PLACEHOLDER %t.out &> %t.txt || true
96
// RUN: %CPU_RUN_PLACEHOLDER FileCheck %s --input-file %t.txt
@@ -27,6 +24,7 @@
2724

2825
#include "Inputs/kernels_in_file2.hpp"
2926
#include <CL/sycl.hpp>
27+
#include <cstdio>
3028
#include <iostream>
3129
#include <thread>
3230

@@ -85,6 +83,15 @@ void runTestForTid(queue *Q, size_t Tid) {
8583
}
8684

8785
int main(int Argc, const char *Argv[]) {
86+
#ifndef __SYCL_DEVICE_ONLY__
87+
// On windows stderr output becomes messed up if several thread
88+
// output simultaneously. Hence, setting explicit line buffering here.
89+
if (setvbuf(stderr, nullptr, _IOLBF, BUFSIZ)) {
90+
std::cerr << "Can't set line-buffering mode fo stderr\n";
91+
return 1;
92+
}
93+
#endif
94+
8895
std::vector<std::thread> threadPool;
8996
threadPool.reserve(NUM_THREADS);
9097

SYCL/AtomicRef/add.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// See https://github.com/intel/llvm-test-suite/issues/867 for detailed status
22
// UNSUPPORTED: hip
33

4-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-device-code-split=per_kernel -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
4+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-device-code-split=per_kernel -fsycl-targets=%sycl_triple %s -o %t.out
55
// RUN: %HOST_RUN_PLACEHOLDER %t.out
66
// RUN: %GPU_RUN_PLACEHOLDER %t.out
77
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/add.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -287,10 +287,6 @@ template <access::address_space space, typename T, typename Difference = T,
287287
void add_test_scopes(queue q, size_t N) {
288288
std::vector<memory_scope> scopes =
289289
q.get_device().get_info<info::device::atomic_memory_scope_capabilities>();
290-
if (std::find(scopes.begin(), scopes.end(), memory_scope::system) !=
291-
scopes.end()) {
292-
add_test<space, T, Difference, order, memory_scope::system>(q, N);
293-
}
294290
if (std::find(scopes.begin(), scopes.end(), memory_scope::work_group) !=
295291
scopes.end()) {
296292
add_test<space, T, Difference, order, memory_scope::work_group>(q, N);

SYCL/AtomicRef/add_generic.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/add_generic_local.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/add_generic_local_native_fp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/add_generic_native_fp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/add_local.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out
55
// RUN: %ACC_RUN_PLACEHOLDER %t.out
66

7-
// Barrier is not supported on host. HIP and ACC do not support floating
8-
// point atomics.
9-
// XFAIL: host, hip, acc
7+
// Barrier is not supported on host. HIP does not support floating point
8+
// atomics.
9+
// XFAIL: host, hip
1010

1111
#include "add.h"
1212

SYCL/AtomicRef/add_local_native_fp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/add_native_fp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/and.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/and.h

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -136,10 +136,6 @@ template <access::address_space space, typename T,
136136
void and_test_scopes(queue q) {
137137
std::vector<memory_scope> scopes =
138138
q.get_device().get_info<info::device::atomic_memory_scope_capabilities>();
139-
if (std::find(scopes.begin(), scopes.end(), memory_scope::system) !=
140-
scopes.end()) {
141-
and_test<space, T, order, memory_scope::system>(q);
142-
}
143139
if (std::find(scopes.begin(), scopes.end(), memory_scope::work_group) !=
144140
scopes.end()) {
145141
and_test<space, T, order, memory_scope::work_group>(q);

SYCL/AtomicRef/and_generic.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/and_generic_local.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

SYCL/AtomicRef/and_local.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out -Xsycl-target-backend=nvptx64-nvidia-cuda --cuda-gpu-arch=sm_70
1+
// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
22
// RUN: %HOST_RUN_PLACEHOLDER %t.out
33
// RUN: %GPU_RUN_PLACEHOLDER %t.out
44
// RUN: %CPU_RUN_PLACEHOLDER %t.out

0 commit comments

Comments
 (0)