Skip to content

[UR][CTS] Replace urEnqueueEventsWait with dummy event in waitlist tests#21671

Open
kswiecicki wants to merge 2 commits intointel:syclfrom
kswiecicki:ur-cts-mem-buffer-read-fix
Open

[UR][CTS] Replace urEnqueueEventsWait with dummy event in waitlist tests#21671
kswiecicki wants to merge 2 commits intointel:syclfrom
kswiecicki:ur-cts-mem-buffer-read-fix

Conversation

@kswiecicki
Copy link
Copy Markdown
Contributor

InvalidNullPtrEventWaitList tests used urEnqueueEventsWait as the first
operation on a queue to create a valid event for validation testing.
This triggers a hang in the L0 driver when multiple test shards
concurrently call zeCommandListAppendSignalEvent +
zeCommandListHostSynchronize on immediate command lists.

Replace with urEventCreateWithNativeHandle(0, ...) which creates a
dummy event without enqueuing any work, avoiding the L0 driver
concurrency issue entirely. The validation layer rejects invalid
waitlist arguments before reaching the adapter, so the dummy event
is sufficient for these tests.

InvalidNullPtrEventWaitList tests used urEnqueueEventsWait as the first
operation on a queue to create a valid event for validation testing.
This triggers a hang in the L0 driver when multiple test shards
concurrently call zeCommandListAppendSignalEvent +
zeCommandListHostSynchronize on immediate command lists.

Replace with urEventCreateWithNativeHandle(0, ...) which creates a
dummy event without enqueuing any work, avoiding the L0 driver
concurrency issue entirely. The validation layer rejects invalid
waitlist arguments before reaching the adapter, so the dummy event
is sufficient for these tests.
Comment on lines +154 to +156
uur::raii::Event eventDummy = nullptr;
ASSERT_SUCCESS(
urEventCreateWithNativeHandle(0, context, nullptr, eventDummy.ptr()));
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't equivalent to urEnqueueEventsWait. It will not wait for the preceding operations on the queue.

Copy link
Copy Markdown
Contributor

@pbalcer pbalcer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the actual issue in L0? Hang if zeCommandListAppendSignalEvent is immediately followed by zeCommandListHostSynchronize, when the command list is otherwise empty?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants