Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
This commit is contained in:
Kamil Kopryk 2022-07-24 23:11:47 +00:00 committed by Compute-Runtime-Automation
parent 137959c647
commit d29abb7955
2 changed files with 2 additions and 2 deletions

View File

@ -38,7 +38,7 @@ struct KernelHw : public KernelImp {
uint64_t baseAddress = alloc->getGpuAddressToPatch();
auto sshAlignmentMask = NEO::EncodeSurfaceState<GfxFamily>::getSurfaceBaseAddressAlignmentMask();
// Remove misalligned bytes, accounted for in in bufferOffset patch token
// Remove misaligned bytes, accounted for in bufferOffset patch token
baseAddress &= sshAlignmentMask;
auto misalignedSize = ptrDiff(alloc->getGpuAddressToPatch(), baseAddress);
auto offset = ptrDiff(address, reinterpret_cast<void *>(baseAddress));

View File

@ -1078,7 +1078,7 @@ TEST_F(WddmMemoryManagerTest, GivenOffsetsWhenAllocatingGpuMemHostThenAllocatedO
ASSERT_NE(nullptr, ptr);
size_t baseOffset = 1024;
// misalligned buffer spanning accross 3 pages
// misaligned buffer spanning across 3 pages
auto *gpuAllocation = memoryManager->allocateGraphicsMemoryWithProperties(MockAllocationProperties{rootDeviceIndex, false, 2 * MemoryConstants::pageSize}, (char *)ptr + baseOffset);
// Should be same cpu ptr and gpu ptr
EXPECT_EQ((char *)ptr + baseOffset, gpuAllocation->getUnderlyingBuffer());