Skip to content

Commit

Permalink
Guard USM impl
Browse files Browse the repository at this point in the history
  • Loading branch information
Aidan committed Feb 13, 2024
1 parent 9e4a4e6 commit ac30243
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -544,10 +544,14 @@ struct __result_and_scratch_storage
inline bool
__use_USM_allocations(sycl::queue __queue)
{
#if _ONEDPL_SYCL_USM_HOST_PRESENT
auto __device = __queue.get_device();
if (!__device.has(sycl::aspect::usm_device_allocations))
return false;
return true;
#else
return false;
#endif
}

public:
Expand Down

0 comments on commit ac30243

Please sign in to comment.