Update Pipe Control WA.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
This commit is contained in:
Michal Mrozek
2021-09-14 19:24:43 +00:00
committed by Compute-Runtime-Automation
parent 3c4885ecb8
commit b0898b0610
3 changed files with 20 additions and 20 deletions

View File

@ -684,7 +684,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, CommandStreamReceiverHwTestXeHPAndLater, givenBlock
auto queueSemaphores = findAll<MI_SEMAPHORE_WAIT *>(hwParserCmdQ.cmdList.begin(), hwParserCmdQ.cmdList.end());
auto expectedQueueSemaphoresCount = 1u;
if (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(pDevice->getHardwareInfo())) {
expectedQueueSemaphoresCount += 2;
expectedQueueSemaphoresCount += 1;
}
EXPECT_EQ(expectedQueueSemaphoresCount, queueSemaphores.size());
auto semaphoreCmd = genCmdCast<MI_SEMAPHORE_WAIT *>(*(queueSemaphores[0]));

View File

@ -100,10 +100,9 @@ HWTEST_F(MockExperimentalCommandBufferTest, givenEnabledExperimentalCmdBufferWhe
ASSERT_NE(nullptr, pipeControl);
EXPECT_EQ(1u, pipeControl->getCommandStreamerStallEnable());
it++;
}
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
}
}
//2nd PIPE_CONTROL with ts addr
@ -138,10 +137,9 @@ HWTEST_F(MockExperimentalCommandBufferTest, givenEnabledExperimentalCmdBufferWhe
pipeControl = genCmdCast<PIPE_CONTROL *>(*it);
ASSERT_NE(nullptr, pipeControl);
EXPECT_EQ(1u, pipeControl->getCommandStreamerStallEnable());
}
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
}
}
//4th PIPE_CONTROL with ts addr
@ -239,10 +237,11 @@ HWTEST_F(MockExperimentalCommandBufferTest, givenEnabledExperimentalCmdBufferWhe
GenCmdList::iterator end = hwParserExCmdBuffer.cmdList.end();
if (MemorySynchronizationCommands<FamilyType>::isPipeControlWArequired(pDevice->getHardwareInfo())) {
it++;
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
}
}
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
}
//2nd PIPE_CONTROL
uint64_t timeStampAddress = mockExCmdBuffer->timestamps->getGpuAddress() + 2 * sizeof(uint64_t);
uint32_t expectedTsAddress = static_cast<uint32_t>(timeStampAddress & 0x0000FFFFFFFFULL);
@ -257,10 +256,11 @@ HWTEST_F(MockExperimentalCommandBufferTest, givenEnabledExperimentalCmdBufferWhe
//omit SEMAPHORE_WAIT and 3rd PIPE_CONTROL
if (MemorySynchronizationCommands<FamilyType>::isPipeControlWArequired(pDevice->getHardwareInfo())) {
it++;
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
}
}
if (UnitTestHelper<FamilyType>::isAdditionalSynchronizationRequired()) {
it++;
}
it++;
//get 4th PIPE_CONTROL
timeStampAddress = mockExCmdBuffer->timestamps->getGpuAddress() + 3 * sizeof(uint64_t);

View File

@ -1277,7 +1277,7 @@ HWTEST_F(TimestampPacketTests, givenAlreadyAssignedNodeWhenEnqueueingToOoqThenDo
semaphoresFound++;
}
}
uint32_t expectedSemaphoresCount = (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo()) ? 2 : 0);
uint32_t expectedSemaphoresCount = (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo()) ? 1 : 0);
EXPECT_EQ(expectedSemaphoresCount, semaphoresFound);
}
@ -1303,7 +1303,7 @@ HWTEST_F(TimestampPacketTests, givenAlreadyAssignedNodeWhenEnqueueingWithOmitTim
semaphoresFound++;
}
}
uint32_t expectedSemaphoresCount = (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo()) ? 2 : 0);
uint32_t expectedSemaphoresCount = (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo()) ? 1 : 0);
EXPECT_EQ(expectedSemaphoresCount, semaphoresFound);
}
@ -1543,7 +1543,7 @@ HWTEST_F(TimestampPacketTests, givenBlockedEnqueueWithoutKernelWhenSubmittingThe
auto queueSemaphores = findAll<MI_SEMAPHORE_WAIT *>(hwParserCmdQ.cmdList.begin(), hwParserCmdQ.cmdList.end());
auto expectedQueueSemaphoresCount = 1u;
if (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo())) {
expectedQueueSemaphoresCount += 2;
expectedQueueSemaphoresCount += 1;
}
EXPECT_EQ(expectedQueueSemaphoresCount, queueSemaphores.size());
verifySemaphore(genCmdCast<MI_SEMAPHORE_WAIT *>(*(queueSemaphores[0])), node0.getNode(0), 0);
@ -1597,7 +1597,7 @@ HWTEST_F(TimestampPacketTests, givenWaitlistAndOutputEventWhenEnqueueingMarkerWi
auto queueSemaphores = findAll<MI_SEMAPHORE_WAIT *>(hwParserCmdQ.cmdList.begin(), hwParserCmdQ.cmdList.end());
auto expectedQueueSemaphoresCount = 1u;
if (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo())) {
expectedQueueSemaphoresCount += 2;
expectedQueueSemaphoresCount += 1;
}
EXPECT_EQ(expectedQueueSemaphoresCount, queueSemaphores.size());
verifySemaphore(genCmdCast<MI_SEMAPHORE_WAIT *>(*(queueSemaphores[0])), node1.getNode(0), 0);
@ -1640,7 +1640,7 @@ HWTEST_F(TimestampPacketTests, givenWaitlistAndOutputEventWhenEnqueueingBarrierW
auto queueSemaphores = findAll<MI_SEMAPHORE_WAIT *>(hwParserCmdQ.cmdList.begin(), hwParserCmdQ.cmdList.end());
auto expectedQueueSemaphoresCount = 1u;
if (UnitTestHelper<FamilyType>::isAdditionalMiSemaphoreWaitRequired(device->getHardwareInfo())) {
expectedQueueSemaphoresCount += 2;
expectedQueueSemaphoresCount += 1;
}
EXPECT_EQ(expectedQueueSemaphoresCount, queueSemaphores.size());
verifySemaphore(genCmdCast<MI_SEMAPHORE_WAIT *>(*(queueSemaphores[0])), node1.getNode(0), 0);