mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-23 11:03:02 +08:00
use release for cl-objects instead of delete
- fix for data race in events - modification of the addition child event Change-Id: I6ea3a413f13f13a91d37d20d8b9fad37d0ffafb9
This commit is contained in:
committed by
sys_ocldev
parent
3820a5e8e5
commit
e1eab521e7
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2017-2018 Intel Corporation
|
||||
* Copyright (C) 2017-2019 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -10,6 +10,7 @@
|
||||
#include "runtime/helpers/engine_control.h"
|
||||
#include "runtime/helpers/task_information.h"
|
||||
#include "runtime/helpers/dispatch_info.h"
|
||||
#include "runtime/event/user_event.h"
|
||||
#include "instrumentation.h"
|
||||
#include <atomic>
|
||||
#include <cstdint>
|
||||
@@ -341,6 +342,13 @@ class CommandQueue : public BaseObject<_cl_command_queue> {
|
||||
|
||||
MOCKABLE_VIRTUAL void releaseIndirectHeap(IndirectHeap::Type heapType);
|
||||
|
||||
void releaseVirtualEvent() {
|
||||
if (this->virtualEvent != nullptr) {
|
||||
this->virtualEvent->decRefInternal();
|
||||
this->virtualEvent = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
cl_command_queue_properties getCommandQueueProperties() const {
|
||||
return commandQueueProperties;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user