Skip to content

Commit 42d06a9

Browse files
nrspruitAlexeySachkov
authored andcommitted
[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. Signed-off-by: Neil R. Spruit <[email protected]>
1 parent e2ea53b commit 42d06a9

File tree

1 file changed

+4
-0
lines changed
  • unified-runtime/source/adapters/level_zero

1 file changed

+4
-0
lines changed

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

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,8 @@ ur_result_t urBindlessImagesWaitExternalSemaphoreExp(
146146
(ZeCommandList, 1, &hExtSemaphore, &WaitParams, ZeEvent,
147147
WaitList.Length, WaitList.ZeEventList));
148148

149+
UR_CALL(hQueue->executeCommandList(CommandList, false, OkToBatch));
150+
149151
return UR_RESULT_SUCCESS;
150152
}
151153

@@ -203,6 +205,8 @@ ur_result_t urBindlessImagesSignalExternalSemaphoreExp(
203205
(ZeCommandList, 1, &hExtSemaphore, &SignalParams, ZeEvent,
204206
WaitList.Length, WaitList.ZeEventList));
205207

208+
UR_CALL(hQueue->executeCommandList(CommandList, false, OkToBatch));
209+
206210
return UR_RESULT_SUCCESS;
207211
}
208212

0 commit comments

Comments
 (0)