fix: initialize context with first submission in heapless execution

- early return from initializeDeviceWithFirstSubmission if flush was
already called

Related-To: NEO-11219

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
This commit is contained in:
Mateusz Hoppe
2024-05-24 13:46:53 +00:00
committed by Compute-Runtime-Automation
parent 0a74d718f2
commit a2a154ba4a
3 changed files with 21 additions and 1 deletions

View File

@@ -135,10 +135,12 @@ ze_result_t CommandQueueHw<gfxCoreFamily>::executeCommandListsRegularHeapless(
ze_event_handle_t hSignalEvent, uint32_t numWaitEvents,
ze_event_handle_t *phWaitEvents) {
auto neoDevice = this->device->getNEODevice();
this->csr->initializeDeviceWithFirstSubmission(*neoDevice);
this->setupCmdListsAndContextParams(ctx, commandListHandles, numCommandLists, hFence);
ctx.isDirectSubmissionEnabled = this->csr->isDirectSubmissionEnabled();
bool instructionCacheFlushRequired = this->csr->isInstructionCacheFlushRequired();
auto neoDevice = this->device->getNEODevice();
bool stateCacheFlushRequired = neoDevice->getBindlessHeapsHelper() ? neoDevice->getBindlessHeapsHelper()->getStateDirtyForContext(this->csr->getOsContext().getContextId()) : false;
std::unique_lock<std::mutex> lockForIndirect;