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

Commit a92d98e

Browse files
authored
[SYCL] Test global_work_size query has the right errc (#1660)
1 parent ac564a6 commit a92d98e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

SYCL/Basic/kernel_info.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,4 +51,12 @@ int main() {
5151
const size_t prefWGSizeMult = krn.get_info<
5252
info::kernel_device_specific::preferred_work_group_size_multiple>(dev);
5353
assert(prefWGSizeMult > 0);
54+
55+
try {
56+
krn.get_info<sycl::info::kernel_device_specific::global_work_size>(dev);
57+
assert(dev.get_info<sycl::info::device::device_type>() ==
58+
sycl::info::device_type::custom);
59+
} catch (sycl::exception &e) {
60+
assert(e.code() == sycl::errc::invalid);
61+
}
5462
}

0 commit comments

Comments
 (0)