mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-07 21:27:04 +08:00
Add flag for forcing usage of hostPtrTracking
Change-Id: I1a7c27145fcb23a54d49edf24659225621dd4496
This commit is contained in:
@@ -2187,6 +2187,15 @@ HWTEST_F(MemoryAllocatorTest, givenMemoryManagerWhen64BitAndHostPtrTrackingDisab
|
||||
EXPECT_EQ(expectedValue, result);
|
||||
}
|
||||
|
||||
HWTEST_F(MemoryAllocatorTest, givenMemoryManagerWhenHostPtrTrackingModeThenNonSvmHostPtrUsageIsSet) {
|
||||
memoryManager->setForceNonSvmForExternalHostPtr(true);
|
||||
|
||||
auto result = memoryManager->useNonSvmHostPtrAlloc(GraphicsAllocation::AllocationType::EXTERNAL_HOST_PTR);
|
||||
EXPECT_EQ(true, result);
|
||||
result = memoryManager->useNonSvmHostPtrAlloc(GraphicsAllocation::AllocationType::BUFFER_HOST_MEMORY);
|
||||
EXPECT_EQ(false, result);
|
||||
}
|
||||
|
||||
HWTEST_F(MemoryAllocatorTest, givenMemoryManagerWhenHostPtrTrackingEnabledThenNonSvmHostPtrUsageDependsOnFullRangeSvm) {
|
||||
DebugManagerStateRestore dbgRestore;
|
||||
DebugManager.flags.EnableHostPtrTracking.set(1);
|
||||
|
||||
Reference in New Issue
Block a user