mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
Move aub center and command stream receivers to root device environment
resize root device environments to 1 by default Related-To: NEO-3691, NEO-3857 Change-Id: Idf3d61e84f8265f30381c18216632d0ffb2a16de Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
eccb9f044d
commit
d408b82a19
@@ -9,13 +9,13 @@
|
||||
#include "common/helpers/bit_helpers.h"
|
||||
#include "core/command_stream/preemption_mode.h"
|
||||
#include "core/helpers/aligned_memory.h"
|
||||
#include "core/helpers/common_types.h"
|
||||
#include "core/memory_manager/gfx_partition.h"
|
||||
#include "core/memory_manager/graphics_allocation.h"
|
||||
#include "core/memory_manager/host_ptr_defines.h"
|
||||
#include "core/memory_manager/local_memory_usage.h"
|
||||
#include "core/page_fault_manager/cpu_page_fault_manager.h"
|
||||
#include "public/cl_ext_private.h"
|
||||
#include "runtime/helpers/common_types.h"
|
||||
#include "runtime/helpers/engine_control.h"
|
||||
#include "runtime/memory_manager/allocation_properties.h"
|
||||
|
||||
|
||||
@@ -213,11 +213,12 @@ void OsAgnosticMemoryManager::freeGraphicsMemoryImpl(GraphicsAllocation *gfxAllo
|
||||
releaseReservedCpuAddressRange(gfxAllocation->getReservedAddressPtr(), gfxAllocation->getReservedAddressSize());
|
||||
}
|
||||
|
||||
auto aubCenter = executionEnvironment.aubCenter.get();
|
||||
if (aubCenter && aubCenter->getAubManager() && DebugManager.flags.EnableFreeMemory.get()) {
|
||||
aubCenter->getAubManager()->freeMemory(gfxAllocation->getGpuAddress(), gfxAllocation->getUnderlyingBufferSize());
|
||||
if (executionEnvironment.rootDeviceEnvironments.size() > 0) {
|
||||
auto aubCenter = executionEnvironment.rootDeviceEnvironments[0].aubCenter.get();
|
||||
if (aubCenter && aubCenter->getAubManager() && DebugManager.flags.EnableFreeMemory.get()) {
|
||||
aubCenter->getAubManager()->freeMemory(gfxAllocation->getGpuAddress(), gfxAllocation->getUnderlyingBufferSize());
|
||||
}
|
||||
}
|
||||
|
||||
delete gfxAllocation;
|
||||
}
|
||||
|
||||
@@ -257,7 +258,7 @@ MemoryManager::AllocationStatus OsAgnosticMemoryManager::populateOsHandles(OsHan
|
||||
void OsAgnosticMemoryManager::cleanOsHandles(OsHandleStorage &handleStorage) {
|
||||
for (unsigned int i = 0; i < maxFragmentsCount; i++) {
|
||||
if (handleStorage.fragmentStorageData[i].freeTheFragment) {
|
||||
auto aubCenter = executionEnvironment.aubCenter.get();
|
||||
auto aubCenter = executionEnvironment.rootDeviceEnvironments[0].aubCenter.get();
|
||||
if (aubCenter && aubCenter->getAubManager() && DebugManager.flags.EnableFreeMemory.get()) {
|
||||
aubCenter->getAubManager()->freeMemory((uint64_t)handleStorage.fragmentStorageData[i].cpuPtr, handleStorage.fragmentStorageData[i].fragmentSize);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user