From c58d0478cf3c025c9ee5148ade6d513edadb217a Mon Sep 17 00:00:00 2001 From: Marcin Hajder Date: Thu, 29 Aug 2024 18:15:01 +0200 Subject: [PATCH] Added default device from context to be available for CL_SEMAPHORE_DEVICE_HANDLE_LIST_KHR query --- layers/11_semaemu/emulate.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/layers/11_semaemu/emulate.cpp b/layers/11_semaemu/emulate.cpp index 6200ff4..f2bfd53 100644 --- a/layers/11_semaemu/emulate.cpp +++ b/layers/11_semaemu/emulate.cpp @@ -172,6 +172,17 @@ typedef struct _cl_semaphore_khr { errorCode = CL_INVALID_PROPERTY; } + else + { + cl_device_id device=0; + g_pNextDispatch->clGetContextInfo( + context, + CL_CONTEXT_DEVICES, + sizeof(cl_device_id), + &device, + nullptr); + devices.push_back(device); + } } else {