Skip to content

Commit 35c8f67

Browse files
committed
clang-format fixes
1 parent c3abb3d commit 35c8f67

File tree

2 files changed

+6
-10
lines changed

2 files changed

+6
-10
lines changed

clang/test/CodeGenSYCL/Inputs/sycl.hpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@
55
extern "C" int printf(const char* fmt, ...);
66

77
#ifdef __SYCL_DEVICE_ONLY__
8-
__attribute__((convergent))
9-
extern SYCL_EXTERNAL void
8+
__attribute__((convergent)) extern SYCL_EXTERNAL void
109
__spirv_ControlBarrier(int, int, int) noexcept;
1110
#endif
1211

clang/test/CodeGenSYCL/reqd-sub-group-size-spirv-intrin.cpp

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,20 @@
11
// RUN: %clang_cc1 -triple spir64 -fsycl-is-device -std=c++17 -internal-isystem %S/Inputs -fdeclare-spirv-builtins %s -emit-llvm -o - | FileCheck %s
22

33
// Test that when __spirv intrinsics are invoked from kernel functions
4-
// that have a sub_group_size specified, that such invocations don't
4+
// that have a sub_group_size specified, that such invocations don't
55
// trigger the error diagnostic that the intrinsic routines must also
66
// marked with the same attribute.
77

88
#include "Inputs/sycl.hpp"
99

1010
int main() {
11-
const int local_size = 8;
12-
const int global_size = 1*local_size;
11+
sycl::queue q;
1312

14-
cl::sycl::queue q;
15-
16-
q.submit([&] (cl::sycl::handler &cgh) {
17-
auto kernel_ = [=](cl::sycl::nd_item<1> item) [[intel::sub_group_size(8)]] {
13+
q.submit([&](sycl::handler &cgh) {
14+
auto kernel_ = [=](sycl::nd_item<1> item) [[intel::sub_group_size(8)]] {
1815
item.barrier(sycl::access::fence_space::local_space);
1916
};
20-
17+
2118
cgh.parallel_for<class kernel_class>(cl::sycl::nd_range<1>(), kernel_);
2219
});
2320
return 0;

0 commit comments

Comments
 (0)