mirror of
https://github.com/intel/compute-runtime.git
synced 2025-09-15 13:01:45 +08:00
Externally synchronized event
Adding support for externally synchronized events inside async events handler Change-Id: Iddc5d3ae25577b792d197aa5b5857618201a3449
This commit is contained in:

committed by
sys_ocldev

parent
c996bad881
commit
1e422813b8
@ -60,7 +60,7 @@ Event *AsyncEventsHandler::processList() {
|
||||
|
||||
for (auto event : list) {
|
||||
event->updateExecutionStatus();
|
||||
if (event->peekHasCallbacks()) {
|
||||
if (event->peekHasCallbacks() || (event->isExternallySynchronized() && (event->peekExecutionStatus() > CL_COMPLETE))) {
|
||||
pendingList.push_back(event);
|
||||
if (event->peekTaskCount() < lowestTaskCount) {
|
||||
sleepCandidate = event;
|
||||
|
@ -308,6 +308,10 @@ class Event : public BaseObject<_cl_event>, public IDNode<Event> {
|
||||
|
||||
std::vector<Event *> &getParentEvents() { return this->parentEvents; }
|
||||
|
||||
virtual bool isExternallySynchronized() const {
|
||||
return false;
|
||||
}
|
||||
|
||||
protected:
|
||||
Event(Context *ctx, CommandQueue *cmdQueue, cl_command_type cmdType,
|
||||
uint32_t taskLevel, uint32_t taskCount);
|
||||
|
Reference in New Issue
Block a user