fix: don't evict always resident allocations

Related-To: NEO-12008

Signed-off-by: Szymon Morek <szymon.morek@intel.com>
This commit is contained in:
Szymon Morek
2024-07-13 14:02:01 +00:00
committed by Compute-Runtime-Automation
parent 64f2312aa0
commit 09cbbc2625
2 changed files with 8 additions and 1 deletions

View File

@@ -676,6 +676,13 @@ TEST_F(WddmCommandStreamTest, WhenMakingNonResidentThenAllocationIsPlacedInEvict
EXPECT_EQ(1u, csr->getEvictionAllocations().size());
csr->getEvictionAllocations().clear();
commandBuffer->updateResidencyTaskCount(GraphicsAllocation::objectAlwaysResident, csr->getOsContext().getContextId());
csr->makeNonResident(*commandBuffer);
EXPECT_EQ(0u, csr->getEvictionAllocations().size());
memoryManager->freeGraphicsMemory(commandBuffer);
}