Skip to content

Commit c19f4fd

Browse files
Re-enable decanonize gpu address on releaseGpuRange() call drm ULT
Signed-off-by: Igor Venevtsev <[email protected]>
1 parent 7883fa3 commit c19f4fd

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

opencl/test/unit_test/os_interface/linux/drm_memory_manager_tests.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3797,13 +3797,14 @@ TEST_F(DrmMemoryManagerTest, givenSvmCpuAllocationWhenSizeAndAlignmentProvidedBu
37973797
EXPECT_EQ(nullptr, allocation);
37983798
}
37993799

3800-
TEST_F(DrmMemoryManagerTest, DISABLED_givenDrmMemoryManagerAndReleaseGpuRangeIsCalledThenGpuAddressIsDecanonized) {
3800+
TEST_F(DrmMemoryManagerTest, givenDrmMemoryManagerAndReleaseGpuRangeIsCalledThenGpuAddressIsDecanonized) {
3801+
constexpr size_t reservedCpuAddressRangeSize = is64bit ? (6 * 4 * GB) : 0;
3802+
auto hwInfo = defaultHwInfo.get();
38013803
auto mockGfxPartition = std::make_unique<MockGfxPartition>();
3802-
mockGfxPartition->init(maxNBitValue(48), 0, 0, 1);
3804+
mockGfxPartition->init(hwInfo->capabilityTable.gpuAddressSpace, reservedCpuAddressRangeSize, 0, 1);
38033805
auto size = 2 * MemoryConstants::megaByte;
38043806
auto gpuAddress = mockGfxPartition->heapAllocate(HeapIndex::HEAP_STANDARD, size);
38053807
auto gpuAddressCanonized = GmmHelper::canonize(gpuAddress);
3806-
EXPECT_NE(gpuAddress, gpuAddressCanonized);
38073808
EXPECT_LE(gpuAddress, gpuAddressCanonized);
38083809

38093810
EXPECT_CALL(*mockGfxPartition.get(), freeGpuAddressRange(gpuAddress, size));

0 commit comments

Comments
 (0)