-
Notifications
You must be signed in to change notification settings - Fork 790
[SYCL] Don't synchronize last event if it is discarded #8993
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5921,7 +5921,9 @@ pi_result _pi_queue::synchronize() { | |
return PI_SUCCESS; | ||
|
||
// For in-order queue just wait for the last command. | ||
if (isInOrderQueue()) { | ||
// If event is discarded then it can be in reset state or underlying level | ||
// zero handle can have device scope, so we can't synchronize the last event. | ||
if (isInOrderQueue() && !LastCommandEvent->IsDiscarded) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why? Isn't There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh, I guess this is because it may not be host-scope right? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, this is one of the reasons. And the main reason is that this event may be in reset state. Basically we can't explicitly synchronize discarded pi_event objects. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, but please add some comment about it. |
||
ZE_CALL(zeHostSynchronize, (LastCommandEvent->ZeEvent)); | ||
} else { | ||
// Otherwise sync all L0 queues/immediate command-lists. | ||
|
Uh oh!
There was an error while loading. Please reload this page.