mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-25 13:33:02 +08:00
Enhance debug flag for post blit commands
Change-Id: Ia5dccd083d84ab1b7a1e772f7fd1d5344aa3c6b1 Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
971969ba15
commit
21988a81e1
@@ -73,7 +73,7 @@ DECLARE_DEBUG_VARIABLE(int32_t, PauseOnGpuMode, -1, "-1: default (before and aft
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, EnableMultiStorageResources, -1, "-1: default, 0: Disable, 1: Enable")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, LimitBlitterMaxWidth, -1, "-1: default, >=0: Max width")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, LimitBlitterMaxHeight, -1, "-1: default, >=0: Max height")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, FlushAfterEachBlit, -1, "-1: default, 0: disable, 1: enable")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, PostBlitCommand, -1, "-1: default, 0: MI_ARB_CHECK, 1: MI_FLUSH, 2: Nothing")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, OverridePreemptionSurfaceSizeInMb, -1, "-1: default, >=0 Override preemption surface size with value")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, OverrideLeastOccupiedBank, -1, "-1: default, >=0 Override least occupied bank with value")
|
||||
DECLARE_DEBUG_VARIABLE(int32_t, OverrideRevision, -1, "-1: default, >=0: Revision id")
|
||||
|
||||
@@ -41,30 +41,30 @@ uint64_t BlitCommandsHelper<GfxFamily>::getMaxBlitHeight(const RootDeviceEnviron
|
||||
|
||||
template <typename GfxFamily>
|
||||
void BlitCommandsHelper<GfxFamily>::dispatchPostBlitCommand(LinearStream &linearStream) {
|
||||
bool useFlush = false;
|
||||
if (DebugManager.flags.FlushAfterEachBlit.get() != -1) {
|
||||
useFlush = static_cast<bool>(DebugManager.flags.FlushAfterEachBlit.get());
|
||||
}
|
||||
|
||||
if (useFlush) {
|
||||
switch (DebugManager.flags.PostBlitCommand.get()) {
|
||||
case 1:
|
||||
EncodeMiFlushDW<GfxFamily>::programMiFlushDw(linearStream, 0, 0, false, false);
|
||||
} else {
|
||||
break;
|
||||
case 2:
|
||||
break;
|
||||
default: {
|
||||
auto miArbCheckStream = linearStream.getSpaceForCmd<typename GfxFamily::MI_ARB_CHECK>();
|
||||
*miArbCheckStream = GfxFamily::cmdInitArbCheck;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
template <typename GfxFamily>
|
||||
size_t BlitCommandsHelper<GfxFamily>::estimatePostBlitCommandSize() {
|
||||
bool useFlush = false;
|
||||
if (DebugManager.flags.FlushAfterEachBlit.get() != -1) {
|
||||
useFlush = static_cast<bool>(DebugManager.flags.FlushAfterEachBlit.get());
|
||||
}
|
||||
|
||||
if (useFlush) {
|
||||
switch (DebugManager.flags.PostBlitCommand.get()) {
|
||||
case 1:
|
||||
return sizeof(typename GfxFamily::MI_FLUSH_DW);
|
||||
case 2:
|
||||
return 0;
|
||||
default:
|
||||
return sizeof(typename GfxFamily::MI_ARB_CHECK);
|
||||
}
|
||||
return sizeof(typename GfxFamily::MI_ARB_CHECK);
|
||||
}
|
||||
|
||||
template <typename GfxFamily>
|
||||
|
||||
Reference in New Issue
Block a user