Reset cmdList - genericMediaStateClear not required during programSBA

This resolved regressions on Linux/ Windows for SYCL/L0 applications.

Change-Id: I26bd75a0473a5ceace1321d6b3f9613ce2cc5d9d
Signed-off-by: Vinod Tipparaju <vinod.tipparaju@intel.com>
This commit is contained in:
Vinod Tipparaju
2020-09-29 17:26:26 +05:30
committed by sys_ocldev
parent 44a6d70ced
commit deb4cc2444
2 changed files with 0 additions and 40 deletions

View File

@@ -1643,9 +1643,6 @@ void CommandListCoreFamily<gfxCoreFamily>::programStateBaseAddress(NEO::CommandC
NEO::PipeControlArgs args(true);
args.hdcPipelineFlush = true;
args.textureCacheInvalidationEnable = true;
if (genericMediaStateClearRequired) {
args.genericMediaStateClear = true;
}
NEO::MemorySynchronizationCommands<GfxFamily>::addPipeControl(*commandContainer.getCommandStream(), args);
STATE_BASE_ADDRESS sba;

View File

@@ -334,43 +334,6 @@ HWCMDTEST_F(IGFX_GEN8_CORE, CommandListCreate, whenCommandListIsCreatedThenPCAnd
EXPECT_EQ(gmmHelper->getMOCS(GMM_RESOURCE_USAGE_OCL_BUFFER), cmdSba->getStatelessDataPortAccessMemoryObjectControlState());
}
HWTEST_F(CommandListCreate, givenCommandListWhenCreatedThenGenericMediaStateClearBitIsNotSetInThePipeControlCommand) {
using PIPE_CONTROL = typename FamilyType::PIPE_CONTROL;
ze_result_t returnValue;
std::unique_ptr<L0::CommandList> commandList(CommandList::create(productFamily, device, NEO::EngineGroupType::RenderCompute, returnValue));
auto &commandContainer = commandList->commandContainer;
GenCmdList cmdList;
ASSERT_TRUE(FamilyType::PARSE::parseCommandBuffer(
cmdList, ptrOffset(commandContainer.getCommandStream()->getCpuBase(), 0), commandContainer.getCommandStream()->getUsed()));
auto itor = find<PIPE_CONTROL *>(cmdList.begin(), cmdList.end());
ASSERT_NE(cmdList.end(), itor);
auto cmdPc = genCmdCast<PIPE_CONTROL *>(*itor);
EXPECT_FALSE(cmdPc->getGenericMediaStateClear());
}
HWTEST_F(CommandListCreate, givenCommandListWhenResetThenGenericMediaStateClearBitIsSetInThePipeControlCommand) {
using PIPE_CONTROL = typename FamilyType::PIPE_CONTROL;
ze_result_t returnValue;
std::unique_ptr<L0::CommandList> commandList(CommandList::create(productFamily, device, NEO::EngineGroupType::RenderCompute, returnValue));
auto &commandContainer = commandList->commandContainer;
commandList->reset();
GenCmdList cmdList;
ASSERT_TRUE(FamilyType::PARSE::parseCommandBuffer(
cmdList, ptrOffset(commandContainer.getCommandStream()->getCpuBase(), 0), commandContainer.getCommandStream()->getUsed()));
auto itor = find<PIPE_CONTROL *>(cmdList.begin(), cmdList.end());
ASSERT_NE(cmdList.end(), itor);
auto cmdPc = genCmdCast<PIPE_CONTROL *>(*itor);
EXPECT_TRUE(cmdPc->getGenericMediaStateClear());
}
HWTEST_F(CommandListCreate, givenCommandListWithCopyOnlyWhenCreatedThenStateBaseAddressCmdIsNotProgrammed) {
using STATE_BASE_ADDRESS = typename FamilyType::STATE_BASE_ADDRESS;