Skip to content

Commit 2976c7e

Browse files
[SYCL] Cherry-pick UR patches related to bindless images (#20031)
This is a joined cherry-pick of: --- [UR][L0] Remove Driver Exp Implementation of External Semaphore (#19835) - Intel L0 GPU Driver no longer supports the Driver Exp Implementation of External Semaphore and the code has been removed from the codebase, therefore the support needs to be removed from the adapter to allow compiling with newer ze_intel_gpu.h headers. - L0 Spec implementation is the only version required for customer support. Patch-by: Neil R. Spruit <neil.r.spruit@intel.com> --- [UR][L0] urBindlessImagesGetImageMemoryHandleTypeSupportExp correction (#19667) VK_FORMAT_R8G8B8A8_UNORM is supported on L0 urt, correction to verifyCommonImagePropertiesSupport. Patch-by: Zhang, Winston <winston.zhang@intel.com> --- [UR][L0][V2] Fixed supported logic for external semaphore (#19863) Patch-by: Neil R. Spruit <neil.r.spruit@intel.com> --- [UR][L0] Fix Implict Event sync during external semaphore wait/signal (#19859) - When SYCl Calls the L0 adapter without a signal event, L0 creates an internal event. - Given in order command queue, the internal event for the wait/signal is implicitly added to the wait list of the next command if executeCommandList is called. - This ensures that the internal event is properly synchronized with the command queue during that next call given SYCL is failing to create a UR event for tracking the wait/signal. Patch-by: Neil R. Spruit <neil.r.spruit@intel.com>
1 parent 6a3d3ff commit 2976c7e

File tree

7 files changed

+89
-280
lines changed

7 files changed

+89
-280
lines changed

sycl/test-e2e/bindless_images/dx11_interop/read_write_unsampled.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,10 @@ int runTest(D3D11ProgramState &d3d11ProgramState, sycl::queue syclQueue,
213213
// E.g. LevelZero does not support `unorm` channel types.
214214
if (!bindless_helpers::memoryAllocationSupported(
215215
syclImageDesc, syclexp::image_memory_handle_type::opaque_handle,
216-
syclQueue)) {
216+
syclQueue) ||
217+
(channelType == sycl::image_channel_type::unorm_int8 &&
218+
syclQueue.get_device().get_backend() ==
219+
sycl::backend::ext_oneapi_level_zero)) {
217220
// We cannot allocate the image memory, skip the test.
218221
#ifdef VERBOSE_PRINT
219222
std::cout << "Memory allocation unsupported. Skipping test.\n";

sycl/test-e2e/bindless_images/dx12_interop/read_write_unsampled.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -523,6 +523,14 @@ static bool
523523
runTest(DX12SYCLDevice &device, sycl::image_channel_type channelType,
524524
sycl::range<NDims> globalSize, sycl::range<NDims> localSize) {
525525

526+
// Skip unorm_int8 tests for Level Zero backend
527+
if (channelType == sycl::image_channel_type::unorm_int8 &&
528+
device.getSyclQueue().get_device().get_backend() ==
529+
sycl::backend::ext_oneapi_level_zero) {
530+
std::cout << "Skipping unorm_int8 test for Level Zero backend.\n";
531+
return true;
532+
}
533+
526534
syclexp::image_descriptor syclImageDesc{globalSize, NChannels, channelType};
527535

528536
// Verify ability to allocate the above image descriptor.

unified-runtime/source/adapters/level_zero/image.cpp

Lines changed: 23 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -136,44 +136,17 @@ ur_result_t urBindlessImagesWaitExternalSemaphoreExp(
136136
const auto &ZeCommandList = CommandList->first;
137137
const auto &WaitList = (*Event)->WaitList;
138138

139-
if (UrPlatform->ZeExternalSemaphoreExt.LoaderExtension) {
140-
ze_external_semaphore_wait_params_ext_t WaitParams = {
141-
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_WAIT_PARAMS_EXT, nullptr, 0};
142-
WaitParams.value = hasValue ? waitValue : 0;
143-
ze_external_semaphore_ext_handle_t hExtSemaphore =
144-
reinterpret_cast<ze_external_semaphore_ext_handle_t>(hSemaphore);
145-
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
146-
.zexCommandListAppendWaitExternalSemaphoresExp,
147-
(ZeCommandList, 1, &hExtSemaphore, &WaitParams, ZeEvent,
148-
WaitList.Length, WaitList.ZeEventList));
149-
} else {
150-
ze_command_list_handle_t translatedCommandList;
151-
ZE2UR_CALL(zelLoaderTranslateHandle,
152-
(ZEL_HANDLE_COMMAND_LIST, ZeCommandList,
153-
(void **)&translatedCommandList));
154-
ze_event_handle_t translatedEvent = ZeEvent;
155-
if (ZeEvent) {
156-
ZE2UR_CALL(zelLoaderTranslateHandle,
157-
(ZEL_HANDLE_EVENT, ZeEvent, (void **)&translatedEvent));
158-
}
159-
std::vector<ze_event_handle_t> EventHandles(WaitList.Length + 1, nullptr);
160-
if (WaitList.Length > 0) {
161-
for (size_t i = 0; i < WaitList.Length; i++) {
162-
ze_event_handle_t ZeEvent = WaitList.ZeEventList[i];
163-
ZE2UR_CALL(zelLoaderTranslateHandle,
164-
(ZEL_HANDLE_EVENT, ZeEvent, (void **)&EventHandles[i + 1]));
165-
}
166-
}
167-
ze_intel_external_semaphore_wait_params_exp_t WaitParams = {
168-
ZE_INTEL_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_WAIT_PARAMS_EXP, nullptr, 0};
169-
WaitParams.value = hasValue ? waitValue : 0;
170-
const ze_intel_external_semaphore_exp_handle_t hExtSemaphore =
171-
reinterpret_cast<ze_intel_external_semaphore_exp_handle_t>(hSemaphore);
172-
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
173-
.zexExpCommandListAppendWaitExternalSemaphoresExp,
174-
(translatedCommandList, 1, &hExtSemaphore, &WaitParams,
175-
translatedEvent, WaitList.Length, EventHandles.data()));
176-
}
139+
ze_external_semaphore_wait_params_ext_t WaitParams = {
140+
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_WAIT_PARAMS_EXT, nullptr, 0};
141+
WaitParams.value = hasValue ? waitValue : 0;
142+
ze_external_semaphore_ext_handle_t hExtSemaphore =
143+
reinterpret_cast<ze_external_semaphore_ext_handle_t>(hSemaphore);
144+
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
145+
.zexCommandListAppendWaitExternalSemaphoresExp,
146+
(ZeCommandList, 1, &hExtSemaphore, &WaitParams, ZeEvent,
147+
WaitList.Length, WaitList.ZeEventList));
148+
149+
UR_CALL(hQueue->executeCommandList(CommandList, false, OkToBatch));
177150

178151
return UR_RESULT_SUCCESS;
179152
}
@@ -221,47 +194,18 @@ ur_result_t urBindlessImagesSignalExternalSemaphoreExp(
221194
const auto &ZeCommandList = CommandList->first;
222195
const auto &WaitList = (*Event)->WaitList;
223196

224-
if (UrPlatform->ZeExternalSemaphoreExt.LoaderExtension) {
225-
ze_external_semaphore_signal_params_ext_t SignalParams = {
226-
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_EXT, nullptr, 0};
227-
SignalParams.value = hasValue ? signalValue : 0;
228-
ze_external_semaphore_ext_handle_t hExtSemaphore =
229-
reinterpret_cast<ze_external_semaphore_ext_handle_t>(hSemaphore);
230-
231-
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
232-
.zexCommandListAppendSignalExternalSemaphoresExp,
233-
(ZeCommandList, 1, &hExtSemaphore, &SignalParams, ZeEvent,
234-
WaitList.Length, WaitList.ZeEventList));
235-
} else {
236-
ze_intel_external_semaphore_signal_params_exp_t SignalParams = {
237-
ZE_INTEL_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_EXP, nullptr,
238-
0};
239-
SignalParams.value = hasValue ? signalValue : 0;
240-
const ze_intel_external_semaphore_exp_handle_t hExtSemaphore =
241-
reinterpret_cast<ze_intel_external_semaphore_exp_handle_t>(hSemaphore);
242-
243-
ze_command_list_handle_t translatedCommandList;
244-
ZE2UR_CALL(zelLoaderTranslateHandle,
245-
(ZEL_HANDLE_COMMAND_LIST, ZeCommandList,
246-
(void **)&translatedCommandList));
247-
ze_event_handle_t translatedEvent = ZeEvent;
248-
if (ZeEvent) {
249-
ZE2UR_CALL(zelLoaderTranslateHandle,
250-
(ZEL_HANDLE_EVENT, ZeEvent, (void **)&translatedEvent));
251-
}
252-
std::vector<ze_event_handle_t> EventHandles(WaitList.Length + 1, nullptr);
253-
if (WaitList.Length > 0) {
254-
for (size_t i = 0; i < WaitList.Length; i++) {
255-
ze_event_handle_t ZeEvent = WaitList.ZeEventList[i];
256-
ZE2UR_CALL(zelLoaderTranslateHandle,
257-
(ZEL_HANDLE_EVENT, ZeEvent, (void **)&EventHandles[i + 1]));
258-
}
259-
}
260-
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
261-
.zexExpCommandListAppendSignalExternalSemaphoresExp,
262-
(translatedCommandList, 1, &hExtSemaphore, &SignalParams,
263-
translatedEvent, WaitList.Length, EventHandles.data()));
264-
}
197+
ze_external_semaphore_signal_params_ext_t SignalParams = {
198+
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_SIGNAL_PARAMS_EXT, nullptr, 0};
199+
SignalParams.value = hasValue ? signalValue : 0;
200+
ze_external_semaphore_ext_handle_t hExtSemaphore =
201+
reinterpret_cast<ze_external_semaphore_ext_handle_t>(hSemaphore);
202+
203+
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
204+
.zexCommandListAppendSignalExternalSemaphoresExp,
205+
(ZeCommandList, 1, &hExtSemaphore, &SignalParams, ZeEvent,
206+
WaitList.Length, WaitList.ZeEventList));
207+
208+
UR_CALL(hQueue->executeCommandList(CommandList, false, OkToBatch));
265209

266210
return UR_RESULT_SUCCESS;
267211
}

unified-runtime/source/adapters/level_zero/image_common.cpp

Lines changed: 52 additions & 134 deletions
Original file line numberDiff line numberDiff line change
@@ -1016,16 +1016,6 @@ bool verifyCommonImagePropertiesSupport(
10161016
}
10171017
}
10181018

1019-
// Verify unnormalized channel type support.
1020-
// LevelZero currently doesn't support unnormalized channel types.
1021-
switch (pImageFormat->channelType) {
1022-
default:
1023-
break;
1024-
case UR_IMAGE_CHANNEL_TYPE_UNORM_INT8:
1025-
case UR_IMAGE_CHANNEL_TYPE_UNORM_INT16:
1026-
return false;
1027-
}
1028-
10291019
return supported;
10301020
}
10311021

@@ -1358,126 +1348,60 @@ ur_result_t urBindlessImagesImportExternalSemaphoreExp(
13581348
" {} function not supported!", __FUNCTION__);
13591349
return UR_RESULT_ERROR_UNSUPPORTED_FEATURE;
13601350
}
1361-
if (UrPlatform->ZeExternalSemaphoreExt.LoaderExtension) {
1362-
ze_external_semaphore_ext_desc_t SemDesc = {
1363-
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_EXT_DESC, nullptr,
1364-
ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_OPAQUE_FD};
1365-
ze_external_semaphore_ext_handle_t ExtSemaphoreHandle;
1366-
ze_external_semaphore_fd_ext_desc_t FDExpDesc = {
1367-
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_FD_EXT_DESC, nullptr, 0};
1368-
ze_external_semaphore_win32_ext_desc_t Win32ExpDesc = {
1369-
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_WIN32_EXT_DESC, nullptr, nullptr,
1370-
nullptr};
1371-
void *pNext = const_cast<void *>(pExternalSemaphoreDesc->pNext);
1372-
while (pNext != nullptr) {
1373-
const ur_base_desc_t *BaseDesc =
1374-
static_cast<const ur_base_desc_t *>(pNext);
1375-
if (BaseDesc->stype == UR_STRUCTURE_TYPE_EXP_FILE_DESCRIPTOR) {
1376-
auto FileDescriptor =
1377-
static_cast<const ur_exp_file_descriptor_t *>(pNext);
1378-
FDExpDesc.fd = FileDescriptor->fd;
1379-
SemDesc.pNext = &FDExpDesc;
1380-
switch (semHandleType) {
1381-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_OPAQUE_FD:
1382-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_OPAQUE_FD;
1383-
break;
1384-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_TIMELINE_FD:
1385-
SemDesc.flags =
1386-
ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_VK_TIMELINE_SEMAPHORE_FD;
1387-
break;
1388-
default:
1389-
return UR_RESULT_ERROR_INVALID_VALUE;
1390-
}
1391-
} else if (BaseDesc->stype == UR_STRUCTURE_TYPE_EXP_WIN32_HANDLE) {
1392-
SemDesc.pNext = &Win32ExpDesc;
1393-
auto Win32Handle = static_cast<const ur_exp_win32_handle_t *>(pNext);
1394-
switch (semHandleType) {
1395-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_WIN32_NT:
1396-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_OPAQUE_WIN32;
1397-
break;
1398-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_WIN32_NT_DX12_FENCE:
1399-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_D3D12_FENCE;
1400-
break;
1401-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_TIMELINE_WIN32_NT:
1402-
SemDesc.flags =
1403-
ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_VK_TIMELINE_SEMAPHORE_WIN32;
1404-
break;
1405-
default:
1406-
return UR_RESULT_ERROR_INVALID_VALUE;
1407-
}
1408-
Win32ExpDesc.handle = Win32Handle->handle;
1351+
ze_external_semaphore_ext_desc_t SemDesc = {
1352+
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_EXT_DESC, nullptr,
1353+
ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_OPAQUE_FD};
1354+
ze_external_semaphore_ext_handle_t ExtSemaphoreHandle;
1355+
ze_external_semaphore_fd_ext_desc_t FDExpDesc = {
1356+
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_FD_EXT_DESC, nullptr, 0};
1357+
ze_external_semaphore_win32_ext_desc_t Win32ExpDesc = {
1358+
ZE_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_WIN32_EXT_DESC, nullptr, nullptr,
1359+
nullptr};
1360+
void *pNext = const_cast<void *>(pExternalSemaphoreDesc->pNext);
1361+
while (pNext != nullptr) {
1362+
const ur_base_desc_t *BaseDesc = static_cast<const ur_base_desc_t *>(pNext);
1363+
if (BaseDesc->stype == UR_STRUCTURE_TYPE_EXP_FILE_DESCRIPTOR) {
1364+
auto FileDescriptor =
1365+
static_cast<const ur_exp_file_descriptor_t *>(pNext);
1366+
FDExpDesc.fd = FileDescriptor->fd;
1367+
SemDesc.pNext = &FDExpDesc;
1368+
switch (semHandleType) {
1369+
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_OPAQUE_FD:
1370+
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_OPAQUE_FD;
1371+
break;
1372+
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_TIMELINE_FD:
1373+
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_VK_TIMELINE_SEMAPHORE_FD;
1374+
break;
1375+
default:
1376+
return UR_RESULT_ERROR_INVALID_VALUE;
14091377
}
1410-
pNext = const_cast<void *>(BaseDesc->pNext);
1411-
}
1412-
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt.zexImportExternalSemaphoreExp,
1413-
(hDevice->ZeDevice, &SemDesc, &ExtSemaphoreHandle));
1414-
*phExternalSemaphoreHandle =
1415-
(ur_exp_external_semaphore_handle_t)ExtSemaphoreHandle;
1416-
1417-
} else {
1418-
ze_intel_external_semaphore_exp_desc_t SemDesc = {
1419-
ZE_INTEL_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_EXP_DESC, nullptr,
1420-
ZE_EXTERNAL_SEMAPHORE_EXP_FLAGS_OPAQUE_FD};
1421-
ze_intel_external_semaphore_exp_handle_t ExtSemaphoreHandle;
1422-
ze_intel_external_semaphore_desc_fd_exp_desc_t FDExpDesc = {
1423-
ZE_INTEL_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_FD_EXP_DESC, nullptr, 0};
1424-
_ze_intel_external_semaphore_win32_exp_desc_t Win32ExpDesc = {
1425-
ZE_INTEL_STRUCTURE_TYPE_EXTERNAL_SEMAPHORE_WIN32_EXP_DESC, nullptr,
1426-
nullptr, nullptr};
1427-
void *pNext = const_cast<void *>(pExternalSemaphoreDesc->pNext);
1428-
while (pNext != nullptr) {
1429-
const ur_base_desc_t *BaseDesc =
1430-
static_cast<const ur_base_desc_t *>(pNext);
1431-
if (BaseDesc->stype == UR_STRUCTURE_TYPE_EXP_FILE_DESCRIPTOR) {
1432-
auto FileDescriptor =
1433-
static_cast<const ur_exp_file_descriptor_t *>(pNext);
1434-
FDExpDesc.fd = FileDescriptor->fd;
1435-
SemDesc.pNext = &FDExpDesc;
1436-
switch (semHandleType) {
1437-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_OPAQUE_FD:
1438-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXP_FLAGS_OPAQUE_FD;
1439-
break;
1440-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_TIMELINE_FD:
1441-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXP_FLAGS_TIMELINE_SEMAPHORE_FD;
1442-
break;
1443-
default:
1444-
return UR_RESULT_ERROR_INVALID_VALUE;
1445-
}
1446-
} else if (BaseDesc->stype == UR_STRUCTURE_TYPE_EXP_WIN32_HANDLE) {
1447-
SemDesc.pNext = &Win32ExpDesc;
1448-
auto Win32Handle = static_cast<const ur_exp_win32_handle_t *>(pNext);
1449-
switch (semHandleType) {
1450-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_WIN32_NT:
1451-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXP_FLAGS_OPAQUE_WIN32;
1452-
break;
1453-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_WIN32_NT_DX12_FENCE:
1454-
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXP_FLAGS_D3D12_FENCE;
1455-
break;
1456-
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_TIMELINE_WIN32_NT:
1457-
SemDesc.flags =
1458-
ZE_EXTERNAL_SEMAPHORE_EXP_FLAGS_TIMELINE_SEMAPHORE_WIN32;
1459-
break;
1460-
default:
1461-
return UR_RESULT_ERROR_INVALID_VALUE;
1462-
}
1463-
Win32ExpDesc.handle = Win32Handle->handle;
1378+
} else if (BaseDesc->stype == UR_STRUCTURE_TYPE_EXP_WIN32_HANDLE) {
1379+
SemDesc.pNext = &Win32ExpDesc;
1380+
auto Win32Handle = static_cast<const ur_exp_win32_handle_t *>(pNext);
1381+
switch (semHandleType) {
1382+
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_WIN32_NT:
1383+
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_OPAQUE_WIN32;
1384+
break;
1385+
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_WIN32_NT_DX12_FENCE:
1386+
SemDesc.flags = ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_D3D12_FENCE;
1387+
break;
1388+
case UR_EXP_EXTERNAL_SEMAPHORE_TYPE_TIMELINE_WIN32_NT:
1389+
SemDesc.flags =
1390+
ZE_EXTERNAL_SEMAPHORE_EXT_FLAG_VK_TIMELINE_SEMAPHORE_WIN32;
1391+
break;
1392+
default:
1393+
return UR_RESULT_ERROR_INVALID_VALUE;
14641394
}
1465-
pNext = const_cast<void *>(BaseDesc->pNext);
1395+
Win32ExpDesc.handle = Win32Handle->handle;
14661396
}
1467-
1468-
ze_device_handle_t translatedDevice;
1469-
ZE2UR_CALL(zelLoaderTranslateHandle, (ZEL_HANDLE_DEVICE, hDevice->ZeDevice,
1470-
(void **)&translatedDevice));
1471-
// If the L0 loader is not aware of the extension, the handles need to be
1472-
// translated
1473-
ZE2UR_CALL(
1474-
UrPlatform->ZeExternalSemaphoreExt.zexExpImportExternalSemaphoreExp,
1475-
(translatedDevice, &SemDesc, &ExtSemaphoreHandle));
1476-
1477-
*phExternalSemaphoreHandle =
1478-
(ur_exp_external_semaphore_handle_t)ExtSemaphoreHandle;
1397+
pNext = const_cast<void *>(BaseDesc->pNext);
14791398
}
14801399

1400+
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt.zexImportExternalSemaphoreExp,
1401+
(hDevice->ZeDevice, &SemDesc, &ExtSemaphoreHandle));
1402+
*phExternalSemaphoreHandle =
1403+
(ur_exp_external_semaphore_handle_t)ExtSemaphoreHandle;
1404+
14811405
return UR_RESULT_SUCCESS;
14821406
}
14831407

@@ -1490,15 +1414,9 @@ ur_result_t urBindlessImagesReleaseExternalSemaphoreExp(
14901414
" {} function not supported!", __FUNCTION__);
14911415
return UR_RESULT_ERROR_UNSUPPORTED_FEATURE;
14921416
}
1493-
if (UrPlatform->ZeExternalSemaphoreExt.LoaderExtension) {
1494-
ZE2UR_CALL(
1495-
UrPlatform->ZeExternalSemaphoreExt.zexDeviceReleaseExternalSemaphoreExp,
1496-
((ze_external_semaphore_ext_handle_t)hExternalSemaphore));
1497-
} else {
1498-
ZE2UR_CALL(UrPlatform->ZeExternalSemaphoreExt
1499-
.zexExpDeviceReleaseExternalSemaphoreExp,
1500-
((ze_intel_external_semaphore_exp_handle_t)hExternalSemaphore));
1501-
}
1417+
ZE2UR_CALL(
1418+
UrPlatform->ZeExternalSemaphoreExt.zexDeviceReleaseExternalSemaphoreExp,
1419+
((ze_external_semaphore_ext_handle_t)hExternalSemaphore));
15021420

15031421
return UR_RESULT_SUCCESS;
15041422
}

0 commit comments

Comments
 (0)