mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-08 22:12:59 +08:00
Create internal BOs with map offset
Resolves: NEO-5097 Change-Id: I842f3d482420373cc630d5bfc034e229fa2cb30c Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
da524fa03d
commit
a939c89d91
@@ -468,7 +468,7 @@ GraphicsAllocation *MemoryManager::allocateGraphicsMemory(const AllocationData &
|
||||
bool useLocalMem = heapAssigner.useExternal32BitHeap(allocationData.type) ? HwHelper::get(hwInfo->platform.eRenderCoreFamily).heapInLocalMem(*hwInfo) : false;
|
||||
return allocate32BitGraphicsMemoryImpl(allocationData, useLocalMem);
|
||||
}
|
||||
if (allocationData.flags.isUSMHostAllocation) {
|
||||
if (allocationData.flags.isUSMHostAllocation && allocationData.hostPtr) {
|
||||
return allocateUSMHostGraphicsMemory(allocationData);
|
||||
}
|
||||
if (allocationData.hostPtr) {
|
||||
|
||||
@@ -181,6 +181,11 @@ void *SVMAllocsManager::createUnifiedMemoryAllocation(uint32_t rootDeviceIndex,
|
||||
unifiedMemoryProperties.flags.shareable = memoryProperties.allocationFlags.flags.shareable;
|
||||
unifiedMemoryProperties.flags.isUSMDeviceAllocation = true;
|
||||
|
||||
if (memoryProperties.memoryType == InternalMemoryType::HOST_UNIFIED_MEMORY) {
|
||||
unifiedMemoryProperties.flags.isUSMHostAllocation = true;
|
||||
unifiedMemoryProperties.flags.isUSMDeviceAllocation = false;
|
||||
}
|
||||
|
||||
GraphicsAllocation *unifiedMemoryAllocation = memoryManager->allocateGraphicsMemoryWithProperties(unifiedMemoryProperties);
|
||||
if (!unifiedMemoryAllocation) {
|
||||
return nullptr;
|
||||
|
||||
Reference in New Issue
Block a user