Skip to content

Commit 2bd7c87

Browse files
aelovikov-intelbb-sycl
authored andcommitted
[SYCL] Check for aspect::fp64 in ESIMD/api/*ops_heavy.cpp (intel#1248)
1 parent ae039f7 commit 2bd7c87

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

SYCL/ESIMD/api/unary_ops_heavy.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// Exclude PVC not to run same test cases twice (via the *_pvc.cpp variant).
99
// REQUIRES: gpu && !gpu-intel-pvc
1010
// UNSUPPORTED: cuda || hip
11-
// RUN: %clangxx -fsycl %s -o %t.out
11+
// RUN: %clangxx -fsycl-device-code-split=per_kernel -fsycl %s -o %t.out
1212
// RUN: %GPU_RUN_PLACEHOLDER %t.out
1313

1414
// Tests various unary operations applied to simd objects.
@@ -174,7 +174,8 @@ int main(void) {
174174
passed &= test<half, 1>(mod_ops, q);
175175
passed &= test<half, 32>(mod_ops, q);
176176
passed &= test<float, 32>(mod_ops, q);
177-
passed &= test<double, 7>(mod_ops, q);
177+
if (dev.has(aspect::fp64))
178+
passed &= test<double, 7>(mod_ops, q);
178179

179180
auto signed_ops = esimd_test::OpSeq<UnOp, UnOp::minus, UnOp::plus>{};
180181
passed &= test<char, 7>(signed_ops, q);
@@ -183,7 +184,8 @@ int main(void) {
183184
passed &= test<int64_t, 16>(signed_ops, q);
184185
passed &= test<half, 16>(signed_ops, q);
185186
passed &= test<float, 16>(signed_ops, q);
186-
passed &= test<double, 16>(signed_ops, q);
187+
if (dev.has(aspect::fp64))
188+
passed &= test<double, 16>(signed_ops, q);
187189

188190
#ifdef USE_BF16
189191
// TODO: the rest unary operations are not yet supported for bfloat16 on host.

0 commit comments

Comments
 (0)