mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-07 21:27:04 +08:00
fix: request instruction cache invalidation on module destroy
Invalidation is requested on both linux and windows, on Csr's that used Isa allocation. Related-To: NEO-10045 Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
64175d8bb6
commit
c51b656d2c
@@ -304,6 +304,10 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushImmediateTask(
|
||||
flushData.estimatedSize += MemorySynchronizationCommands<GfxFamily>::getSizeForFullCacheFlush();
|
||||
}
|
||||
|
||||
if (requiresInstructionCacheFlush) {
|
||||
flushData.estimatedSize += MemorySynchronizationCommands<GfxFamily>::getSizeForInstructionCacheFlush();
|
||||
}
|
||||
|
||||
auto &csrCommandStream = getCS(flushData.estimatedSize);
|
||||
flushData.csrStartOffset = csrCommandStream.getUsed();
|
||||
|
||||
@@ -312,6 +316,11 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushImmediateTask(
|
||||
MemorySynchronizationCommands<GfxFamily>::addStateCacheFlush(csrCommandStream, device.getRootDeviceEnvironment());
|
||||
}
|
||||
|
||||
if (requiresInstructionCacheFlush) {
|
||||
MemorySynchronizationCommands<GfxFamily>::addInstructionCacheFlush(csrCommandStream);
|
||||
requiresInstructionCacheFlush = false;
|
||||
}
|
||||
|
||||
dispatchImmediateFlushPipelineSelectCommand(flushData, csrCommandStream);
|
||||
dispatchImmediateFlushFrontEndCommand(flushData, device, csrCommandStream);
|
||||
dispatchImmediateFlushStateComputeModeCommand(flushData, csrCommandStream);
|
||||
@@ -540,9 +549,7 @@ CompletionStamp CommandStreamReceiverHw<GfxFamily>::flushTask(
|
||||
}
|
||||
|
||||
if (requiresInstructionCacheFlush) {
|
||||
PipeControlArgs args;
|
||||
args.instructionCacheInvalidateEnable = true;
|
||||
MemorySynchronizationCommands<GfxFamily>::addSingleBarrier(commandStreamCSR, args);
|
||||
MemorySynchronizationCommands<GfxFamily>::addInstructionCacheFlush(commandStreamCSR);
|
||||
requiresInstructionCacheFlush = false;
|
||||
}
|
||||
|
||||
@@ -942,7 +949,7 @@ size_t CommandStreamReceiverHw<GfxFamily>::getRequiredCmdStreamSize(const Dispat
|
||||
}
|
||||
|
||||
if (requiresInstructionCacheFlush) {
|
||||
size += MemorySynchronizationCommands<GfxFamily>::getSizeForSingleBarrier(false);
|
||||
size += MemorySynchronizationCommands<GfxFamily>::getSizeForInstructionCacheFlush();
|
||||
}
|
||||
|
||||
if (debugManager.flags.ForcePipeControlPriorToWalker.get()) {
|
||||
|
||||
Reference in New Issue
Block a user