Move temporary and reusable allocation lists to command stream receiver

Change-Id: I40df6fe39b367e243e3710c5fdeaab3c85198d9d
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2018-10-09 11:50:58 +02:00
committed by sys_ocldev
parent 9e8af5e045
commit 8a9d0a81df
30 changed files with 323 additions and 282 deletions

View File

@@ -892,15 +892,14 @@ TEST_F(EventTests, enqueueReadImageBlockedOnUserEvent) {
TEST_F(EventTests, waitForEventsDestroysTemporaryAllocations) {
auto &csr = pCmdQ->getDevice().getCommandStreamReceiver();
MemoryManager *memoryManager = csr.getMemoryManager();
//kill some temporary objects that fixture creates.
csr.waitForTaskCountAndCleanAllocationList(-1, TEMPORARY_ALLOCATION);
EXPECT_TRUE(memoryManager->graphicsAllocations.peekIsEmpty());
EXPECT_TRUE(csr.getTemporaryAllocations().peekIsEmpty());
GraphicsAllocation *temporaryAllocation = csr.createAllocationAndHandleResidency((void *)0x1234, 200);
EXPECT_EQ(temporaryAllocation, memoryManager->graphicsAllocations.peekHead());
EXPECT_EQ(temporaryAllocation, csr.getTemporaryAllocations().peekHead());
temporaryAllocation->taskCount = 10;
@@ -910,7 +909,7 @@ TEST_F(EventTests, waitForEventsDestroysTemporaryAllocations) {
event.waitForEvents(1, eventWaitList);
EXPECT_TRUE(memoryManager->graphicsAllocations.peekIsEmpty());
EXPECT_TRUE(csr.getTemporaryAllocations().peekIsEmpty());
}
TEST_F(EventTest, UserEvent_Wait_NonBlocking) {