mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-21 09:14:47 +08:00
Refactor Sip Kernel usage
Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
da779d067f
commit
8198a739c8
@@ -7,6 +7,7 @@
|
||||
|
||||
#include "shared/source/execution_environment/execution_environment.h"
|
||||
|
||||
#include "shared/source/built_ins/built_ins.h"
|
||||
#include "shared/source/execution_environment/root_device_environment.h"
|
||||
#include "shared/source/helpers/hw_helper.h"
|
||||
#include "shared/source/memory_manager/memory_manager.h"
|
||||
@@ -19,6 +20,11 @@ ExecutionEnvironment::ExecutionEnvironment() = default;
|
||||
ExecutionEnvironment::~ExecutionEnvironment() {
|
||||
if (memoryManager) {
|
||||
memoryManager->commonCleanup();
|
||||
for (const auto &rootDeviceEnvironment : this->rootDeviceEnvironments) {
|
||||
if (rootDeviceEnvironment->builtins.get()) {
|
||||
rootDeviceEnvironment->builtins.get()->freeSipKernels(memoryManager.get());
|
||||
}
|
||||
}
|
||||
}
|
||||
rootDeviceEnvironments.clear();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user