Fix L0 CommandQueue command buffer allocation properties

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
Bartosz Dunajski 2021-09-21 13:45:04 +00:00 committed by Compute-Runtime-Automation
parent 2707618fe3
commit a2e41716e2
2 changed files with 2 additions and 1 deletions

View File

@ -167,7 +167,7 @@ ze_result_t CommandQueueImp::CommandBufferManager::initialize(Device *device, si
size_t alignedSize = alignUp<size_t>(sizeRequested, MemoryConstants::pageSize64k);
NEO::AllocationProperties properties{device->getRootDeviceIndex(), true, alignedSize,
NEO::GraphicsAllocation::AllocationType::COMMAND_BUFFER,
device->isMultiDeviceCapable(),
(device->getNEODevice()->getNumGenericSubDevices() > 1u) /* multiOsContextCapable */,
false,
device->getNEODevice()->getDeviceBitfield()};

View File

@ -1856,6 +1856,7 @@ TEST_F(CommandQueueInitTests, givenMultipleSubDevicesWhenInitializingThenAllocat
if (allocationProperties.allocationType == NEO::GraphicsAllocation::AllocationType::COMMAND_BUFFER) {
cmdBufferAllocationsFound++;
EXPECT_EQ(expectedBitfield, allocationProperties.subDevicesBitfield.to_ulong());
EXPECT_EQ(1u, allocationProperties.flags.multiOsContextCapable);
}
}