[L0] Use immediate command lists for external semaphore wait/signal#21930
Merged
Conversation
The L0 spec requires zeCommandListAppendWaitExternalSemaphoreExt and zeCommandListAppendSignalExternalSemaphoreExt to be called on immediate command lists. On Gen12, queues default to regular (non-immediate) command lists, causing these calls to fail with ZE_RESULT_ERROR_INVALID_ARGUMENT. Fix by obtaining an immediate command list via getImmCmdList() when the queue is not already using immediate command lists, ensuring external semaphore operations work on all platforms including Gen12. Fixes: URLZA-723
cperkinsintel
approved these changes
May 5, 2026
Contributor
|
@intel/llvm-gatekeepers please consider merging |
pbalcer
approved these changes
May 6, 2026
Contributor
|
@intel/llvm-gatekeepers please consider merging |
Merged
uditagarwal97
pushed a commit
that referenced
this pull request
May 19, 2026
Revert "[L0] Use immediate command lists for external semaphore wait/signal (#21930)" This reverts commit e928aae. By putting the semaphore on an immediate command list, but still using the original regular command list for the other graphic operations, we introduce some unsoundness that can lead to races and problems where the regular command list is the default. The better choice in the short term is to simply require that SYCL queues that are intended for semaphore usage use immediate command lists. I have a separate PR (in progress) that will make that change to the docs and tests and introduces a verification. #22046
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The L0 spec requires zeCommandListAppendWaitExternalSemaphoreExt and zeCommandListAppendSignalExternalSemaphoreExt to be called on immediate command lists. On Gen12, queues default to regular (non-immediate) command lists, causing these calls to fail with
ZE_RESULT_ERROR_INVALID_ARGUMENT.
Fix by obtaining an immediate command list via getImmCmdList() when the queue is not already using immediate command lists, ensuring external semaphore operations work on all platforms including Gen12.