File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed
DirectProgramming/C++SYCL_FPGA/Tutorials/DesignPatterns/io_streaming/src Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -66,16 +66,13 @@ class ProducerConsumerBaseImpl {
6666 // check for USM support
6767 device d = q.get_device ();
6868
69- #if defined (IS_BSP)
70- // make sure the device supports USM device allocations in BSP mode
71- if (!d.get_info <info::device::usm_host_allocations>() && use_host_alloc) {
69+ if (use_host_alloc && !d.get_info <info::device::usm_host_allocations>()) {
7270 std::cerr << " ERROR: The selected device does not support USM host"
7371 << " allocations\n " ;
7472 std::terminate ();
7573 }
76- #endif
7774
78- if (!d.get_info <info::device::usm_device_allocations>()) {
75+ if (!use_host_alloc && ! d.get_info <info::device::usm_device_allocations>()) {
7976 std::cerr << " ERROR: The selected device does not support USM device"
8077 << " allocations\n " ;
8178 std::terminate ();
You can’t perform that action at this time.
0 commit comments