mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-07 12:42:54 +08:00
Use StreamProperties from CSR when programming STATE_COMPUTE_MODE
Related-To: NEO-5995 Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
ac2b1d403b
commit
e5d7142ae0
@@ -258,25 +258,27 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushTask(
|
||||
dispatchFlags.pipelineSelectArgs.specialPipelineSelectMode,
|
||||
peekHwInfo());
|
||||
|
||||
if (dispatchFlags.threadArbitrationPolicy != ThreadArbitrationPolicy::NotPresent) {
|
||||
this->requiredThreadArbitrationPolicy = dispatchFlags.threadArbitrationPolicy;
|
||||
}
|
||||
if (dispatchFlags.numGrfRequired == GrfConfig::NotApplicable) {
|
||||
dispatchFlags.numGrfRequired = lastSentNumGrfRequired;
|
||||
}
|
||||
|
||||
this->streamProperties.stateComputeMode.setProperties(dispatchFlags.requiresCoherency, dispatchFlags.numGrfRequired,
|
||||
this->requiredThreadArbitrationPolicy);
|
||||
|
||||
csrSizeRequestFlags.l3ConfigChanged = this->lastSentL3Config != newL3Config;
|
||||
csrSizeRequestFlags.coherencyRequestChanged = this->lastSentCoherencyRequest != static_cast<int8_t>(dispatchFlags.requiresCoherency);
|
||||
csrSizeRequestFlags.preemptionRequestChanged = this->lastPreemptionMode != dispatchFlags.preemptionMode;
|
||||
csrSizeRequestFlags.mediaSamplerConfigChanged = this->lastMediaSamplerConfig != static_cast<int8_t>(dispatchFlags.pipelineSelectArgs.mediaSamplerRequired);
|
||||
csrSizeRequestFlags.specialPipelineSelectModeChanged = isSpecialPipelineSelectModeChanged;
|
||||
|
||||
if (dispatchFlags.numGrfRequired == GrfConfig::NotApplicable) {
|
||||
dispatchFlags.numGrfRequired = lastSentNumGrfRequired;
|
||||
}
|
||||
|
||||
csrSizeRequestFlags.numGrfRequiredChanged = this->lastSentNumGrfRequired != dispatchFlags.numGrfRequired;
|
||||
lastSentNumGrfRequired = dispatchFlags.numGrfRequired;
|
||||
|
||||
csrSizeRequestFlags.activePartitionsChanged = isProgramActivePartitionConfigRequired();
|
||||
|
||||
if (dispatchFlags.threadArbitrationPolicy != ThreadArbitrationPolicy::NotPresent) {
|
||||
this->requiredThreadArbitrationPolicy = dispatchFlags.threadArbitrationPolicy;
|
||||
}
|
||||
|
||||
auto force32BitAllocations = getMemoryManager()->peekForce32BitAllocations();
|
||||
bool stateBaseAddressDirty = false;
|
||||
|
||||
|
||||
@@ -24,19 +24,16 @@ void CommandStreamReceiverHw<GfxFamily>::programComputeMode(LinearStream &stream
|
||||
auto hwInfoConfig = HwInfoConfig::get(hwInfo.platform.eProductFamily);
|
||||
if (hwInfoConfig->isPipeControlPriorToNonPipelinedStateCommandsWARequired(hwInfo, isRcs())) {
|
||||
PipeControlArgs args(true);
|
||||
|
||||
addPipeControlPriorToNonPipelinedStateCommand(stream, args);
|
||||
}
|
||||
|
||||
StreamProperties properties{};
|
||||
properties.stateComputeMode.setProperties(dispatchFlags.requiresCoherency, dispatchFlags.numGrfRequired,
|
||||
this->requiredThreadArbitrationPolicy);
|
||||
EncodeComputeMode<GfxFamily>::programComputeModeCommand(stream, properties.stateComputeMode, hwInfo);
|
||||
EncodeComputeMode<GfxFamily>::programComputeModeCommand(stream, this->streamProperties.stateComputeMode, hwInfo);
|
||||
|
||||
if (csrSizeRequestFlags.hasSharedHandles) {
|
||||
auto pc = stream.getSpaceForCmd<PIPE_CONTROL>();
|
||||
*pc = GfxFamily::cmdInitPipeControl;
|
||||
}
|
||||
|
||||
programAdditionalPipelineSelect(stream, dispatchFlags.pipelineSelectArgs, false);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user