mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-07 21:27:04 +08:00
Add isDcFlushAllowed function to HwInfoConfig
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
4d906328e1
commit
0fd685541d
@@ -261,6 +261,12 @@ template <>
|
||||
bool HwInfoConfigHw<IGFX_UNKNOWN>::isTile64With3DSurfaceOnBCSSupported(const HardwareInfo &hwInfo) const {
|
||||
return false;
|
||||
}
|
||||
|
||||
template <>
|
||||
bool HwInfoConfigHw<IGFX_UNKNOWN>::isDcFlushAllowed() const {
|
||||
return true;
|
||||
}
|
||||
|
||||
template <>
|
||||
uint32_t HwInfoConfigHw<IGFX_UNKNOWN>::computeMaxNeededSubSliceSpace(const HardwareInfo &hwInfo) const {
|
||||
return hwInfo.gtSystemInfo.MaxSubSlicesSupported;
|
||||
|
||||
@@ -309,7 +309,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, CommandEncodeStatesTest, givenEventAddressWhenEncod
|
||||
auto itor = find<WALKER_TYPE *>(commands.begin(), commands.end());
|
||||
ASSERT_NE(itor, commands.end());
|
||||
auto cmd = genCmdCast<WALKER_TYPE *>(*itor);
|
||||
if (MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true)) {
|
||||
if (MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo)) {
|
||||
EXPECT_EQ(pDevice->getGmmHelper()->getMOCS(GMM_RESOURCE_USAGE_OCL_BUFFER_CACHELINE_MISALIGNED), cmd->getPostSync().getMocs());
|
||||
} else {
|
||||
EXPECT_EQ(pDevice->getGmmHelper()->getMOCS(GMM_RESOURCE_USAGE_OCL_BUFFER), cmd->getPostSync().getMocs());
|
||||
|
||||
@@ -30,7 +30,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenGetSizeWhenDispatchingCm
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, false, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(32, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, 0u);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, 0u, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(2u, partitionCount);
|
||||
@@ -72,7 +72,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenWorkgroupOneAndNoPartiti
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, false, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(1, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, false, false, false, 0u);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, false, false, false, 0u, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(1u, partitionCount);
|
||||
@@ -115,7 +115,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenWorkgroupOneAndPartition
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, false, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(1, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, 0u);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, 0u, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(1u, partitionCount);
|
||||
@@ -161,7 +161,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenStaticPartitioningWhenDi
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, true, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(32, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(2u, partitionCount);
|
||||
@@ -212,7 +213,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenStaticPartitioningWhenPa
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, true, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(32, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(2u, partitionCount);
|
||||
@@ -265,7 +267,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenStaticPartitioningPrefer
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, true, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(1, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -315,7 +318,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenStaticPartitioningPrefer
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, true, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(1, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -351,7 +355,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenStaticPartitioningPrefer
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, true, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(1, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -387,7 +392,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests, GivenDynamicPartitioningPrefe
|
||||
expectedSize = ImplicitScalingDispatch<FamilyType>::getSize(false, false, twoTile, Vec3<size_t>(0, 0, 0), Vec3<size_t>(1, 1, 1));
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -434,7 +440,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -501,7 +508,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -560,7 +568,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -619,7 +628,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -685,7 +695,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -747,7 +758,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -811,7 +823,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -878,7 +891,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, true, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
@@ -944,7 +958,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, ImplicitScalingTests,
|
||||
EXPECT_EQ(expectedSize, estimatedSize);
|
||||
|
||||
uint32_t partitionCount = 0;
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false, workPartitionAllocationAddress);
|
||||
ImplicitScalingDispatch<FamilyType>::dispatchCommands(commandStream, walker, twoTile, partitionCount, true, false, false,
|
||||
workPartitionAllocationAddress, *defaultHwInfo);
|
||||
totalBytesProgrammed = commandStream.getUsed();
|
||||
EXPECT_EQ(expectedSize, totalBytesProgrammed);
|
||||
EXPECT_EQ(twoTile.count(), partitionCount);
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include "shared/source/helpers/hw_helper.h"
|
||||
#include "shared/test/common/helpers/default_hw_info.h"
|
||||
#include "shared/test/common/helpers/unit_test_helper.h"
|
||||
#include "shared/test/unit_test/encoders/walker_partition_fixture_xehp_and_later.h"
|
||||
|
||||
@@ -46,7 +47,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenWalkerPartitionWhenConst
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
auto wparidMaskProgrammingLocation = cmdBufferAddress;
|
||||
@@ -99,7 +101,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenWalkerPartitionWhenConst
|
||||
|
||||
auto pipeControl = genCmdCast<WalkerPartition::PIPE_CONTROL<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
|
||||
@@ -164,7 +166,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWhe
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
EXPECT_EQ(controlSectionOffset + sizeof(StaticPartitioningControlSection), totalBytesProgrammed);
|
||||
|
||||
auto parsedOffset = 0u;
|
||||
@@ -187,7 +190,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWhe
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -243,7 +246,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionAnd
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
EXPECT_EQ(controlSectionOffset + sizeof(StaticPartitioningControlSection), totalBytesProgrammed);
|
||||
|
||||
auto parsedOffset = 0u;
|
||||
@@ -285,7 +289,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionAnd
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -340,7 +344,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionAnd
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
EXPECT_EQ(controlSectionOffset, totalBytesProgrammed);
|
||||
|
||||
auto parsedOffset = 0u;
|
||||
@@ -363,7 +368,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionAnd
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miSemaphoreWait = genCmdCast<WalkerPartition::MI_SEMAPHORE_WAIT<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -426,7 +431,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
const auto expectedBytesProgrammed = WalkerPartition::estimateSpaceRequiredInCommandBuffer<FamilyType>(testArgs);
|
||||
EXPECT_EQ(expectedBytesProgrammed, totalBytesProgrammed);
|
||||
|
||||
@@ -459,7 +465,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -574,7 +580,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
const auto expectedBytesProgrammed = WalkerPartition::estimateSpaceRequiredInCommandBuffer<FamilyType>(testArgs);
|
||||
EXPECT_EQ(expectedBytesProgrammed, totalBytesProgrammed);
|
||||
|
||||
@@ -607,7 +614,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -722,7 +729,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
const auto expectedBytesProgrammed = WalkerPartition::estimateSpaceRequiredInCommandBuffer<FamilyType>(testArgs);
|
||||
EXPECT_EQ(expectedBytesProgrammed, totalBytesProgrammed);
|
||||
|
||||
@@ -757,7 +765,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -877,7 +885,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
const auto expectedBytesProgrammed = WalkerPartition::estimateSpaceRequiredInCommandBuffer<FamilyType>(testArgs);
|
||||
EXPECT_EQ(expectedBytesProgrammed, totalBytesProgrammed);
|
||||
|
||||
@@ -912,7 +921,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWit
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
}
|
||||
{
|
||||
auto miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -1050,7 +1059,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenDebugModesForWalkerParti
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
auto wparidMaskProgrammingLocation = cmdBufferAddress;
|
||||
@@ -1103,7 +1113,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenDebugModesForWalkerParti
|
||||
|
||||
auto pipeControl = genCmdCast<WalkerPartition::PIPE_CONTROL<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
|
||||
@@ -1169,7 +1179,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWhe
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
const auto expectedBytesProgrammed = WalkerPartition::estimateSpaceRequiredInCommandBuffer<FamilyType>(testArgs);
|
||||
EXPECT_EQ(expectedBytesProgrammed, totalBytesProgrammed);
|
||||
|
||||
@@ -1207,7 +1218,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticWalkerPartitionWhe
|
||||
cmdBufferGpuAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
const auto expectedBytesProgrammed = WalkerPartition::estimateSpaceRequiredInCommandBuffer<FamilyType>(testArgs);
|
||||
EXPECT_EQ(expectedBytesProgrammed, totalBytesProgrammed);
|
||||
|
||||
@@ -1269,7 +1281,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticPartitionIsPreferr
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
|
||||
@@ -1319,7 +1332,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenStaticPartitionIsPreferr
|
||||
|
||||
auto pipeControl = genCmdCast<WalkerPartition::PIPE_CONTROL<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
|
||||
miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/test/common/helpers/default_hw_info.h"
|
||||
#include "shared/test/unit_test/encoders/walker_partition_fixture_xehp_and_later.h"
|
||||
|
||||
HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenProgramRegisterCommandWhenItIsCalledThenLoadRegisterImmIsSetUnderPointer) {
|
||||
@@ -34,7 +35,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenWalkerPartitionWhenConst
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
auto totalProgrammedSize = computeControlSectionOffset<FamilyType>(testArgs) +
|
||||
sizeof(BatchBufferControlData);
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
@@ -875,7 +877,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenSelfCleanupSectionWhenDe
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
auto wparidMaskProgrammingLocation = cmdBufferAddress;
|
||||
@@ -936,7 +939,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenSelfCleanupSectionWhenDe
|
||||
auto pipeControl = genCmdCast<WalkerPartition::PIPE_CONTROL<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
|
||||
miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -1076,7 +1079,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenSelfCleanupAndAtomicsUse
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
auto wparidMaskProgrammingLocation = cmdBufferAddress;
|
||||
@@ -1138,7 +1142,7 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenSelfCleanupAndAtomicsUse
|
||||
auto pipeControl = genCmdCast<WalkerPartition::PIPE_CONTROL<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
ASSERT_NE(nullptr, pipeControl);
|
||||
EXPECT_TRUE(pipeControl->getCommandStreamerStallEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true), pipeControl->getDcFlushEnable());
|
||||
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(true, *defaultHwInfo), pipeControl->getDcFlushEnable());
|
||||
parsedOffset += sizeof(WalkerPartition::PIPE_CONTROL<FamilyType>);
|
||||
|
||||
miAtomic = genCmdCast<WalkerPartition::MI_ATOMIC<FamilyType> *>(ptrOffset(cmdBuffer, parsedOffset));
|
||||
@@ -1281,7 +1285,8 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, WalkerPartitionTests, givenDynamicPartitioningWhenP
|
||||
gpuVirtualAddress,
|
||||
&walker,
|
||||
totalBytesProgrammed,
|
||||
testArgs);
|
||||
testArgs,
|
||||
*defaultHwInfo);
|
||||
|
||||
EXPECT_EQ(totalProgrammedSize, totalBytesProgrammed);
|
||||
auto wparidMaskProgrammingLocation = cmdBufferAddress;
|
||||
|
||||
Reference in New Issue
Block a user