Skip to content

Commit 8c203ef

Browse files
committed
Fix include fails
1 parent 209a5b7 commit 8c203ef

File tree

2 files changed

+7
-11
lines changed

2 files changed

+7
-11
lines changed

sycl/test-e2e/WorkGroupMemory/reduction_free_function.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ template <typename T, typename... Ts> void test_marray() {
165165
assert(buf && "Shared USM allocation failed!");
166166
T expected = 0;
167167
for (int i = 0; i < WGSIZE; ++i) {
168-
buf[i] = ext::intel::math::sqrt(T(i));
168+
buf[i] = T(i) / WGSIZE;
169169
expected = expected + buf[i];
170170
}
171171
nd_range ndr{{SIZE}, {WGSIZE}};
@@ -194,7 +194,7 @@ template <typename T, typename... Ts> void test_vec() {
194194
assert(buf && "Shared USM allocation failed!");
195195
T expected = 0;
196196
for (int i = 0; i < WGSIZE; ++i) {
197-
buf[i] = ext::intel::math::sqrt(T(i));
197+
buf[i] = T(i) / WGSIZE;
198198
expected = expected + buf[i];
199199
}
200200
nd_range ndr{{SIZE}, {WGSIZE}};

sycl/test-e2e/WorkGroupMemory/reduction_lambda.cpp

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,9 @@ context ctx = q.get_context();
1919

2020
constexpr size_t SIZE = 128;
2121

22-
template <typename T> struct S {
23-
T val;
24-
};
22+
template <typename T> struct S { T val; };
2523

26-
template <typename T> struct M {
27-
T val;
28-
};
24+
template <typename T> struct M { T val; };
2925

3026
union U {
3127
S<int> s;
@@ -43,7 +39,7 @@ void test_struct(size_t SIZE, size_t WGSIZE) {
4339
}
4440
nd_range ndr{{SIZE}, {WGSIZE}};
4541
q.submit([&](sycl::handler &cgh) {
46-
ext::oneapi::experimental::work_group_memory<S<T>[]> mem{WGSIZE, cgh};
42+
ext::oneapi::experimental::work_group_memory<S<T>[]> mem { WGSIZE, cgh };
4743
ext::oneapi::experimental ::work_group_memory<T> result{cgh};
4844
cgh.parallel_for(ndr, [=](nd_item<> it) {
4945
size_t local_id = it.get_local_id();
@@ -148,7 +144,7 @@ template <typename T, typename... Ts> void test_marray() {
148144
assert(buf && "Shared USM allocation failed!");
149145
T expected = 0;
150146
for (int i = 0; i < WGSIZE; ++i) {
151-
buf[i] = T(i);
147+
buf[i] = T(i) / WGSIZE;
152148
expected = expected + buf[i];
153149
}
154150
nd_range ndr{{SIZE}, {WGSIZE}};
@@ -186,7 +182,7 @@ template <typename T, typename... Ts> void test_vec() {
186182
assert(buf && "Shared USM allocation failed!");
187183
T expected = 0;
188184
for (int i = 0; i < WGSIZE; ++i) {
189-
buf[i] = ext::intel::math::sqrt(T(i));
185+
buf[i] = T(i) / WGSIZE;
190186
expected = expected + buf[i];
191187
}
192188
nd_range ndr{{SIZE}, {WGSIZE}};

0 commit comments

Comments
 (0)