Update bits in PC WA

Related-To: NEO-6056

Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
This commit is contained in:
Krzysztof Gibala 2021-10-18 16:47:09 +00:00 committed by Compute-Runtime-Automation
parent f8c89fe984
commit d79317da35
8 changed files with 17 additions and 18 deletions

View File

@ -118,7 +118,6 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, CommandStreamReceiverFlushTaskXeHPAndLaterTests, gi
EXPECT_TRUE(pipeControlCmd->getTextureCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getConstantCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getStateCacheInvalidationEnable());
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(), pipeControlCmd->getDcFlushEnable());
EXPECT_TRUE(pipeControlCmd->getHdcPipelineFlush());
}
@ -150,7 +149,6 @@ HWCMDTEST_F(IGFX_XE_HP_CORE, CommandStreamReceiverFlushTaskXeHPAndLaterTests, gi
EXPECT_TRUE(pipeControlCmd->getCommandStreamerStallEnable());
EXPECT_TRUE(pipeControlCmd->getInstructionCacheInvalidateEnable());
EXPECT_TRUE(pipeControlCmd->getTextureCacheInvalidationEnable());
EXPECT_EQ(MemorySynchronizationCommands<FamilyType>::isDcFlushAllowed(), pipeControlCmd->getDcFlushEnable());
EXPECT_TRUE(pipeControlCmd->getConstantCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getStateCacheInvalidationEnable());

View File

@ -68,7 +68,9 @@ struct ComputeModeRequirements : public ::testing::Test {
template <typename FamilyType>
void SetUpImpl(const NEO::HardwareInfo *hardwareInfo) {
device.reset(MockDevice::createWithNewExecutionEnvironment<MockDevice>(hardwareInfo));
device->executionEnvironment->rootDeviceEnvironments[0]->setHwInfo(hardwareInfo);
csr = new myCsr<FamilyType>(*device->executionEnvironment, device->getDeviceBitfield());
device->resetCommandStreamReceiver(csr);
AllocationProperties properties(device->getRootDeviceIndex(), false, MemoryConstants::pageSize, GraphicsAllocation::AllocationType::SHARED_BUFFER, false, {});

View File

@ -46,7 +46,6 @@ HWTEST2_F(ComputeModeRequirements, GivenProgramPipeControlPriorToNonPipelinedSta
EXPECT_TRUE(pipeControlCmd->getCommandStreamerStallEnable());
EXPECT_TRUE(pipeControlCmd->getInstructionCacheInvalidateEnable());
EXPECT_TRUE(pipeControlCmd->getTextureCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getDcFlushEnable());
EXPECT_TRUE(pipeControlCmd->getConstantCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getStateCacheInvalidationEnable());
@ -60,7 +59,7 @@ HWTEST2_F(ComputeModeRequirements, GivenMultipleCCSEnabledSetupThenCorrectComman
HardwareInfo hwInfo = *defaultHwInfo;
hwInfo.gtSystemInfo.CCSInfo.NumberOfCCSEnabled = 2;
SetUpImpl<FamilyType>();
SetUpImpl<FamilyType>(&hwInfo);
using STATE_COMPUTE_MODE = typename FamilyType::STATE_COMPUTE_MODE;
using PIPE_CONTROL = typename FamilyType::PIPE_CONTROL;
@ -90,7 +89,6 @@ HWTEST2_F(ComputeModeRequirements, GivenMultipleCCSEnabledSetupThenCorrectComman
EXPECT_TRUE(pipeControlCmd->getCommandStreamerStallEnable());
EXPECT_TRUE(pipeControlCmd->getInstructionCacheInvalidateEnable());
EXPECT_TRUE(pipeControlCmd->getTextureCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getDcFlushEnable());
EXPECT_TRUE(pipeControlCmd->getConstantCacheInvalidationEnable());
EXPECT_TRUE(pipeControlCmd->getStateCacheInvalidationEnable());

View File

@ -155,6 +155,8 @@ class CommandStreamReceiverHw : public CommandStreamReceiver {
void programEnginePrologue(LinearStream &csr);
size_t getCmdSizeForPrologue() const;
void setPipeControlPriorToNonPipelinedStateCommandExtraProperties(PipeControlArgs &args);
void addClearSLMWorkAround(typename GfxFamily::PIPE_CONTROL *pCmd);
void addPipeControlCmd(LinearStream &commandStream, PipeControlArgs &args);
void addPipeControlBeforeStateBaseAddress(LinearStream &commandStream);

View File

@ -90,6 +90,9 @@ bool CommandStreamReceiverHw<GfxFamily>::isMultiOsContextCapable() const {
return false;
}
template <typename GfxFamily>
inline void CommandStreamReceiverHw<GfxFamily>::setPipeControlPriorToNonPipelinedStateCommandExtraProperties(PipeControlArgs &args) {}
template <typename GfxFamily>
inline void CommandStreamReceiverHw<GfxFamily>::addPipeControlPriorToNonPipelinedStateCommand(LinearStream &commandStream, PipeControlArgs args) {
addPipeControlCmd(commandStream, args);

View File

@ -23,19 +23,9 @@ void CommandStreamReceiverHw<GfxFamily>::programComputeMode(LinearStream &stream
auto hwInfoConfig = HwInfoConfig::get(hwInfo.platform.eProductFamily);
if (hwInfoConfig->isPipeControlPriorToNonPipelinedStateCommandsWARequired(hwInfo, isRcs())) {
auto pPipeControlSpace = stream.getSpaceForCmd<PIPE_CONTROL>();
PipeControlArgs args(true);
auto pipeControl = GfxFamily::cmdInitPipeControl;
pipeControl.setHdcPipelineFlush(true);
pipeControl.setAmfsFlushEnable(true);
pipeControl.setCommandStreamerStallEnable(true);
pipeControl.setInstructionCacheInvalidateEnable(true);
pipeControl.setTextureCacheInvalidationEnable(true);
pipeControl.setDcFlushEnable(true);
pipeControl.setConstantCacheInvalidationEnable(true);
pipeControl.setStateCacheInvalidationEnable(true);
*pPipeControlSpace = pipeControl;
addPipeControlPriorToNonPipelinedStateCommand(stream, args);
}
auto stateComputeMode = GfxFamily::cmdInitStateComputeMode;

View File

@ -176,9 +176,12 @@ inline void CommandStreamReceiverHw<GfxFamily>::addPipeControlPriorToNonPipeline
args.hdcPipelineFlush = true;
args.amfsFlushEnable = true;
args.instructionCacheInvalidateEnable = true;
args.dcFlushEnable = true;
args.constantCacheInvalidationEnable = true;
args.stateCacheInvalidationEnable = true;
args.dcFlushEnable = false;
setPipeControlPriorToNonPipelinedStateCommandExtraProperties(args);
}
addPipeControlCmd(commandStream, args);

View File

@ -71,6 +71,9 @@ size_t CommandStreamReceiverHw<Family>::getCmdSizeForPerDssBackedBuffer(const Ha
template <>
void CommandStreamReceiverHw<Family>::addPipeControlBefore3dState(LinearStream &commandStream, DispatchFlags &dispatchFlags) {}
template <>
void CommandStreamReceiverHw<Family>::setPipeControlPriorToNonPipelinedStateCommandExtraProperties(PipeControlArgs &args) {}
template <>
void BlitCommandsHelper<Family>::appendClearColor(const BlitProperties &blitProperties, typename Family::XY_COPY_BLT &blitCmd) {
using XY_COPY_BLT = typename Family::XY_COPY_BLT;