mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-08 05:56:36 +08:00
fix: enable 4KB allocation alignment through KMD on Windows
Related-To: NEO-9446 Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
2981c78d34
commit
f91757c093
@@ -1948,10 +1948,12 @@ ze_result_t CommandListCoreFamily<gfxCoreFamily>::appendMemoryFill(void *ptr,
|
||||
size_t patternAllocationSize = alignUp(patternSize, MemoryConstants::cacheLineSize);
|
||||
auto patternGfxAlloc = device->obtainReusableAllocation(patternAllocationSize, NEO::AllocationType::FILL_PATTERN);
|
||||
if (patternGfxAlloc == nullptr) {
|
||||
patternGfxAlloc = device->getDriverHandle()->getMemoryManager()->allocateGraphicsMemoryWithProperties({device->getNEODevice()->getRootDeviceIndex(),
|
||||
patternAllocationSize,
|
||||
NEO::AllocationType::FILL_PATTERN,
|
||||
device->getNEODevice()->getDeviceBitfield()});
|
||||
NEO::AllocationProperties allocationProperties{device->getNEODevice()->getRootDeviceIndex(),
|
||||
patternAllocationSize,
|
||||
NEO::AllocationType::FILL_PATTERN,
|
||||
device->getNEODevice()->getDeviceBitfield()};
|
||||
allocationProperties.alignment = MemoryConstants::pageSize;
|
||||
patternGfxAlloc = device->getDriverHandle()->getMemoryManager()->allocateGraphicsMemoryWithProperties(allocationProperties);
|
||||
}
|
||||
void *patternGfxAllocPtr = patternGfxAlloc->getUnderlyingBuffer();
|
||||
patternAllocations.push_back(patternGfxAlloc);
|
||||
|
||||
Reference in New Issue
Block a user