Add command buffer helpers: Conditional BB_START and GPR Inc/Dec

Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
This commit is contained in:
Dunajski, Bartosz
2022-11-10 09:58:55 +00:00
committed by Compute-Runtime-Automation
parent 9aeb0116d7
commit 002184586c
12 changed files with 537 additions and 21 deletions

View File

@@ -896,7 +896,7 @@ void CommandQueueHw<gfxCoreFamily>::programOneCmdListBatchBufferStart(CommandLis
if (isCommandListImmediate && (iter == (cmdBufferCount - 1))) {
startOffset = ptrOffset(allocation->getGpuAddress(), commandList->commandContainer.currentLinearStreamStartOffset);
}
NEO::EncodeBatchBufferStartOrEnd<GfxFamily>::programBatchBufferStart(&cmdStream, startOffset, true);
NEO::EncodeBatchBufferStartOrEnd<GfxFamily>::programBatchBufferStart(&cmdStream, startOffset, true, false, false);
if (returnPointsSize > 0) {
bool cmdBufferHasRestarts = std::find_if(
std::next(returnPoints.begin(), returnPointIdx),
@@ -914,7 +914,7 @@ void CommandQueueHw<gfxCoreFamily>::programOneCmdListBatchBufferStart(CommandLis
ctx.cmdListBeginState);
NEO::EncodeBatchBufferStartOrEnd<GfxFamily>::programBatchBufferStart(&cmdStream,
returnPoints[returnPointIdx].gpuAddress,
true);
true, false, false);
returnPointIdx++;
}
}
@@ -1041,7 +1041,7 @@ NEO::SubmissionStatus CommandQueueHw<gfxCoreFamily>::prepareAndSubmitBatchBuffer
}
endingCmd = innerCommandStream.getSpace(0);
NEO::EncodeBatchBufferStartOrEnd<GfxFamily>::programBatchBufferStart(&innerCommandStream, startAddress, false);
NEO::EncodeBatchBufferStartOrEnd<GfxFamily>::programBatchBufferStart(&innerCommandStream, startAddress, false, false, false);
} else {
auto buffer = innerCommandStream.getSpaceForCmd<MI_BATCH_BUFFER_END>();
*(MI_BATCH_BUFFER_END *)buffer = GfxFamily::cmdInitBatchBufferEnd;