Revert "Fix multi thread usage of external host alloc"

This reverts commit 54eee2a88b.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
Compute-Runtime-Validation
2022-04-28 16:40:31 +02:00
committed by Compute-Runtime-Automation
parent 46e4a389c2
commit 00a1a14652
12 changed files with 8 additions and 183 deletions

View File

@ -297,25 +297,3 @@ HWTEST_F(InternalAllocationStorageTest, givenMultipleActivePartitionsWhenDetachi
memoryManager->freeGraphicsMemory(allocationReusable.release());
}
TEST_F(InternalAllocationStorageTest, givenInternalAllocationWhenTaskCountMetsExpectationAndItHasBeenAssignedThenAllocIsRemoved) {
auto allocation = memoryManager->allocateGraphicsMemoryWithProperties(MockAllocationProperties{csr->getRootDeviceIndex(), MemoryConstants::pageSize});
uint32_t expectedTaskCount = 10u;
*csr->getTagAddress() = expectedTaskCount;
allocation->updateTaskCount(expectedTaskCount, csr->getOsContext().getContextId());
allocation->hostPtrTaskCountAssignment = 0;
storage->storeAllocation(std::unique_ptr<GraphicsAllocation>(allocation), TEMPORARY_ALLOCATION);
storage->cleanAllocationList(expectedTaskCount, TEMPORARY_ALLOCATION);
EXPECT_TRUE(csr->getTemporaryAllocations().peekIsEmpty());
}
TEST_F(InternalAllocationStorageTest, givenInternalAllocationWhenTaskCountMetsExpectationAndItHasNotBeenAssignedThenAllocIsNotRemoved) {
auto allocation = memoryManager->allocateGraphicsMemoryWithProperties(MockAllocationProperties{csr->getRootDeviceIndex(), MemoryConstants::pageSize});
uint32_t expectedTaskCount = 10u;
*csr->getTagAddress() = expectedTaskCount;
allocation->updateTaskCount(expectedTaskCount, csr->getOsContext().getContextId());
allocation->hostPtrTaskCountAssignment = 1;
storage->storeAllocation(std::unique_ptr<GraphicsAllocation>(allocation), TEMPORARY_ALLOCATION);
storage->cleanAllocationList(expectedTaskCount, TEMPORARY_ALLOCATION);
EXPECT_FALSE(csr->getTemporaryAllocations().peekIsEmpty());
allocation->hostPtrTaskCountAssignment = 0;
}