Create allocations for cmdContainer with device root index 0

Change-Id: Icb0034e87bc27f9c0435f066eebe6a9af3ed9f66
Signed-off-by: Maciej Plewka <maciej.plewka@intel.com>
This commit is contained in:
Maciej Plewka 2019-11-25 15:19:37 +01:00 committed by sys_ocldev
parent b2877d3725
commit f262900bbd
1 changed files with 2 additions and 3 deletions

View File

@ -47,7 +47,7 @@ bool CommandContainer::initialize(Device *device) {
heapHelper = std::unique_ptr<HeapHelper>(new HeapHelper(device->getMemoryManager(), device->getDefaultEngine().commandStreamReceiver->getInternalAllocationStorage(), device->getNumAvailableDevices() > 1u));
size_t alignedSize = alignUp<size_t>(totalCmdBufferSize, MemoryConstants::pageSize64k);
NEO::AllocationProperties properties{device->getRootDeviceIndex(), true /* allocateMemory*/, alignedSize,
NEO::AllocationProperties properties{0u, true /* allocateMemory*/, alignedSize,
GraphicsAllocation::AllocationType::INTERNAL_HOST_MEMORY,
(device->getNumAvailableDevices() > 1u) /* multiOsContextCapable */,
false,
@ -65,7 +65,7 @@ bool CommandContainer::initialize(Device *device) {
size_t heapSize = 65536u;
for (auto &allocationIndirectHeap : allocationIndirectHeaps) {
allocationIndirectHeap = heapHelper->getHeapAllocation(heapSize, alignedSize, device->getRootDeviceIndex());
allocationIndirectHeap = heapHelper->getHeapAllocation(heapSize, alignedSize, 0u);
UNRECOVERABLE_IF(!allocationIndirectHeap);
residencyContainer.push_back(allocationIndirectHeap);
}
@ -83,7 +83,6 @@ bool CommandContainer::initialize(Device *device) {
void CommandContainer::addToResidencyContainer(NEO::GraphicsAllocation *alloc) {
if (alloc == nullptr) {
DEBUG_BREAK_IF(true);
return;
}
auto end = this->residencyContainer.end();