mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-26 15:03:02 +08:00
Refactor L3 programming.
- Do not do it via member setting. - Utilize DispatchFlags Change-Id: I75d4c8ea6c1e10ca0edeeb0d1c3883a549c1cb1f Signed-off-by: Mrozek, Michal <michal.mrozek@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
3528179434
commit
f362739521
@@ -593,17 +593,21 @@ CompletionStamp CommandQueueHw<GfxFamily>::enqueueNonBlocked(
|
||||
previousTimestampPacketNodes->makeResident(getGpgpuCommandStreamReceiver());
|
||||
}
|
||||
|
||||
bool anyUncacheableArgs = false;
|
||||
auto requiresCoherency = false;
|
||||
for (auto surface : CreateRange(surfaces, surfaceCount)) {
|
||||
surface->makeResident(getGpgpuCommandStreamReceiver());
|
||||
requiresCoherency |= surface->IsCoherent;
|
||||
if (!surface->allowsL3Caching()) {
|
||||
anyUncacheableArgs = true;
|
||||
}
|
||||
}
|
||||
|
||||
auto mediaSamplerRequired = false;
|
||||
uint32_t numGrfRequired = GrfConfig::DefaultGrfNumber;
|
||||
auto specialPipelineSelectMode = false;
|
||||
Kernel *kernel = nullptr;
|
||||
bool anyUncacheableArgs = false;
|
||||
|
||||
for (auto &dispatchInfo : multiDispatchInfo) {
|
||||
if (kernel != dispatchInfo.getKernel()) {
|
||||
kernel = dispatchInfo.getKernel();
|
||||
@@ -659,10 +663,6 @@ CompletionStamp CommandQueueHw<GfxFamily>::enqueueNonBlocked(
|
||||
}
|
||||
}
|
||||
|
||||
if (anyUncacheableArgs) {
|
||||
getGpgpuCommandStreamReceiver().setDisableL3Cache(true);
|
||||
}
|
||||
|
||||
DispatchFlags dispatchFlags;
|
||||
dispatchFlags.blocking = blocking;
|
||||
dispatchFlags.dcFlush = shouldFlushDC(commandType, printfHandler) || allocNeedsFlushDC;
|
||||
@@ -685,6 +685,10 @@ CompletionStamp CommandQueueHw<GfxFamily>::enqueueNonBlocked(
|
||||
dispatchFlags.multiEngineQueue = this->multiEngineQueue;
|
||||
DEBUG_BREAK_IF(taskLevel >= Event::eventNotReady);
|
||||
|
||||
if (anyUncacheableArgs) {
|
||||
dispatchFlags.l3CacheSettings = L3CachingSettings::l3CacheOff;
|
||||
}
|
||||
|
||||
if (gtpinIsGTPinInitialized()) {
|
||||
gtpinNotifyPreFlushTask(this);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user