Enable eviction only when needed flag in wddm

Related-To: NEO-7179

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
This commit is contained in:
Zbigniew Zdanowicz
2022-07-14 22:29:14 +00:00
committed by Compute-Runtime-Automation
parent 02e4ddbdfa
commit aced55243c
2 changed files with 3 additions and 1 deletions

View File

@ -814,7 +814,7 @@ TEST_F(Wddm20Tests, GivenMultipleHandlesWhenMakingResidentThenBytesToTrimIsCorre
EXPECT_EQ(gdi->getMakeResidentArg().NumBytesToTrim, bytesToTrim);
}
TEST_F(Wddm20Tests, WhenMakingNonResidentThenEvictIsCalled) {
TEST_F(Wddm20Tests, WhenMakingNonResidentAndEvictNotNeededThenEvictIsCalledWithProperFlagSet) {
D3DKMT_HANDLE handle = (D3DKMT_HANDLE)0x1234;
gdi->getEvictArg().AllocationList = nullptr;
@ -831,6 +831,7 @@ TEST_F(Wddm20Tests, WhenMakingNonResidentThenEvictIsCalled) {
EXPECT_EQ(&handle, gdi->getEvictArg().AllocationList);
EXPECT_EQ(wddm->getDeviceHandle(), gdi->getEvictArg().hDevice);
EXPECT_EQ(0u, gdi->getEvictArg().NumBytesToTrim);
EXPECT_EQ(1u, gdi->getEvictArg().Flags.EvictOnlyIfNecessary);
}
TEST_F(Wddm20Tests, givenDestroyAllocationWhenItIsCalledThenAllocationIsPassedToDestroyAllocation) {