mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-30 09:58:55 +08:00
refactor: rename global debug manager to debugManager
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
f2ede40d2e
commit
c9664e6bad
@@ -58,8 +58,8 @@ CommandContainer::CommandContainer() {
|
||||
|
||||
residencyContainer.reserve(startingResidencyContainerSize);
|
||||
|
||||
if (DebugManager.flags.RemoveUserFenceInCmdlistResetAndDestroy.get() != -1) {
|
||||
isHandleFenceCompletionRequired = !static_cast<bool>(DebugManager.flags.RemoveUserFenceInCmdlistResetAndDestroy.get());
|
||||
if (debugManager.flags.RemoveUserFenceInCmdlistResetAndDestroy.get() != -1) {
|
||||
isHandleFenceCompletionRequired = !static_cast<bool>(debugManager.flags.RemoveUserFenceInCmdlistResetAndDestroy.get());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -216,8 +216,8 @@ void CommandContainer::reset() {
|
||||
|
||||
size_t CommandContainer::getAlignedCmdBufferSize() const {
|
||||
auto totalCommandBufferSize = totalCmdBufferSize;
|
||||
if (DebugManager.flags.OverrideCmdListCmdBufferSizeInKb.get() > 0) {
|
||||
totalCommandBufferSize = static_cast<size_t>(DebugManager.flags.OverrideCmdListCmdBufferSizeInKb.get()) * MemoryConstants::kiloByte;
|
||||
if (debugManager.flags.OverrideCmdListCmdBufferSizeInKb.get() > 0) {
|
||||
totalCommandBufferSize = static_cast<size_t>(debugManager.flags.OverrideCmdListCmdBufferSizeInKb.get()) * MemoryConstants::kiloByte;
|
||||
totalCommandBufferSize += cmdBufferReservedSize;
|
||||
}
|
||||
return alignUp<size_t>(totalCommandBufferSize, defaultCmdBufferAllocationAlignment);
|
||||
|
||||
@@ -436,7 +436,7 @@ void EncodeSurfaceState<Family>::encodeBuffer(EncodeSurfaceStateArgs &args) {
|
||||
setBufferAuxParamsForCCS(surfaceState);
|
||||
}
|
||||
|
||||
if (DebugManager.flags.DisableCachingForStatefulBufferAccess.get()) {
|
||||
if (debugManager.flags.DisableCachingForStatefulBufferAccess.get()) {
|
||||
surfaceState->setMemoryObjectControlState(args.gmmHelper->getMOCS(GMM_RESOURCE_USAGE_OCL_BUFFER_CACHELINE_MISALIGNED));
|
||||
}
|
||||
|
||||
@@ -564,8 +564,8 @@ void *EncodeDispatchKernel<Family>::getInterfaceDescriptor(CommandContainer &con
|
||||
template <typename Family>
|
||||
bool EncodeDispatchKernel<Family>::inlineDataProgrammingRequired(const KernelDescriptor &kernelDesc) {
|
||||
auto checkKernelForInlineData = true;
|
||||
if (DebugManager.flags.EnablePassInlineData.get() != -1) {
|
||||
checkKernelForInlineData = !!DebugManager.flags.EnablePassInlineData.get();
|
||||
if (debugManager.flags.EnablePassInlineData.get() != -1) {
|
||||
checkKernelForInlineData = !!debugManager.flags.EnablePassInlineData.get();
|
||||
}
|
||||
if (checkKernelForInlineData) {
|
||||
return kernelDesc.kernelAttributes.flags.passInlineData;
|
||||
@@ -697,8 +697,8 @@ void EncodeIndirectParams<Family>::setWorkDimIndirect(CommandContainer &containe
|
||||
template <typename Family>
|
||||
bool EncodeSurfaceState<Family>::doBindingTablePrefetch() {
|
||||
auto enableBindingTablePrefetech = isBindingTablePrefetchPreferred();
|
||||
if (DebugManager.flags.ForceBtpPrefetchMode.get() != -1) {
|
||||
enableBindingTablePrefetech = static_cast<bool>(DebugManager.flags.ForceBtpPrefetchMode.get());
|
||||
if (debugManager.flags.ForceBtpPrefetchMode.get() != -1) {
|
||||
enableBindingTablePrefetech = static_cast<bool>(debugManager.flags.ForceBtpPrefetchMode.get());
|
||||
}
|
||||
return enableBindingTablePrefetech;
|
||||
}
|
||||
|
||||
@@ -283,7 +283,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
|
||||
memcpy_s(iddPtr, sizeof(idd), &idd, sizeof(idd));
|
||||
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::DebugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::BeforeWorkload)) {
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::debugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::BeforeWorkload)) {
|
||||
void *commandBuffer = listCmdBufferStream->getSpace(MemorySynchronizationCommands<Family>::getSizeForBarrierWithPostSyncOperation(args.device->getRootDeviceEnvironment(), false));
|
||||
args.additionalCommands->push_back(commandBuffer);
|
||||
|
||||
@@ -303,7 +303,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
|
||||
args.partitionCount = 1;
|
||||
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::DebugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::AfterWorkload)) {
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::debugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::AfterWorkload)) {
|
||||
void *commandBuffer = listCmdBufferStream->getSpace(MemorySynchronizationCommands<Family>::getSizeForBarrierWithPostSyncOperation(args.device->getRootDeviceEnvironment(), false));
|
||||
args.additionalCommands->push_back(commandBuffer);
|
||||
|
||||
|
||||
@@ -26,8 +26,8 @@ void EncodeWA<Family>::addPipeControlBeforeStateBaseAddress(LinearStream &comman
|
||||
|
||||
template <>
|
||||
inline void EncodeMiArbCheck<Family>::adjust(MI_ARB_CHECK &miArbCheck, std::optional<bool> preParserDisable) {
|
||||
if (DebugManager.flags.ForcePreParserEnabledForMiArbCheck.get() != -1) {
|
||||
preParserDisable = !DebugManager.flags.ForcePreParserEnabledForMiArbCheck.get();
|
||||
if (debugManager.flags.ForcePreParserEnabledForMiArbCheck.get() != -1) {
|
||||
preParserDisable = !debugManager.flags.ForcePreParserEnabledForMiArbCheck.get();
|
||||
}
|
||||
if (preParserDisable.has_value()) {
|
||||
miArbCheck.setPreParserDisable(preParserDisable.value());
|
||||
|
||||
@@ -18,9 +18,9 @@ void EncodeSurfaceState<Family>::encodeExtraCacheSettings(R_SURFACE_STATE *surfa
|
||||
auto &productHelper = args.gmmHelper->getRootDeviceEnvironment().getHelper<ProductHelper>();
|
||||
|
||||
auto cachePolicy = static_cast<L1_CACHE_POLICY>(productHelper.getL1CachePolicy(args.isDebuggerActive));
|
||||
if (DebugManager.flags.OverrideL1CacheControlInSurfaceState.get() != -1 &&
|
||||
DebugManager.flags.ForceAllResourcesUncached.get() == false) {
|
||||
cachePolicy = static_cast<L1_CACHE_POLICY>(DebugManager.flags.OverrideL1CacheControlInSurfaceState.get());
|
||||
if (debugManager.flags.OverrideL1CacheControlInSurfaceState.get() != -1 &&
|
||||
debugManager.flags.ForceAllResourcesUncached.get() == false) {
|
||||
cachePolicy = static_cast<L1_CACHE_POLICY>(debugManager.flags.OverrideL1CacheControlInSurfaceState.get());
|
||||
}
|
||||
surfaceState->setL1CachePolicyL1CacheControl(cachePolicy);
|
||||
}
|
||||
|
||||
@@ -106,8 +106,8 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
auto slmSize = static_cast<uint32_t>(
|
||||
gfxCoreHelper.computeSlmValues(hwInfo, args.dispatchInterface->getSlmTotalSize()));
|
||||
|
||||
if (DebugManager.flags.OverrideSlmAllocationSize.get() != -1) {
|
||||
slmSize = static_cast<uint32_t>(DebugManager.flags.OverrideSlmAllocationSize.get());
|
||||
if (debugManager.flags.OverrideSlmAllocationSize.get() != -1) {
|
||||
slmSize = static_cast<uint32_t>(debugManager.flags.OverrideSlmAllocationSize.get());
|
||||
}
|
||||
idd.setSharedLocalMemorySize(slmSize);
|
||||
|
||||
@@ -278,7 +278,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
container.setDirtyStateForAllHeaps(false);
|
||||
}
|
||||
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::DebugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::BeforeWorkload)) {
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::debugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::BeforeWorkload)) {
|
||||
void *commandBuffer = listCmdBufferStream->getSpace(MemorySynchronizationCommands<Family>::getSizeForBarrierWithPostSyncOperation(args.device->getRootDeviceEnvironment(), false));
|
||||
args.additionalCommands->push_back(commandBuffer);
|
||||
|
||||
@@ -322,7 +322,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
EncodeDispatchKernel<Family>::adjustTimestampPacket(walkerCmd, hwInfo);
|
||||
}
|
||||
|
||||
if (DebugManager.flags.ForceComputeWalkerPostSyncFlush.get() == 1) {
|
||||
if (debugManager.flags.ForceComputeWalkerPostSyncFlush.get() == 1) {
|
||||
postSync.setDataportPipelineFlush(true);
|
||||
EncodeDispatchKernel<Family>::adjustTimestampPacket(walkerCmd, hwInfo);
|
||||
}
|
||||
@@ -331,7 +331,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
|
||||
auto threadGroupCount = walkerCmd.getThreadGroupIdXDimension() * walkerCmd.getThreadGroupIdYDimension() * walkerCmd.getThreadGroupIdZDimension();
|
||||
EncodeDispatchKernel<Family>::adjustInterfaceDescriptorData(idd, *args.device, hwInfo, threadGroupCount, kernelDescriptor.kernelAttributes.numGrfRequired, walkerCmd);
|
||||
if (DebugManager.flags.PrintKernelDispatchParameters.get()) {
|
||||
if (debugManager.flags.PrintKernelDispatchParameters.get()) {
|
||||
fprintf(stdout, "kernel, %s, numGrf, %d, simdSize, %d, tilesCount, %d, implicitScaling, %s, threadGroupCount, %d, numberOfThreadsInGpgpuThreadGroup, %d, threadGroupDimensions, %d, %d, %d, threadGroupDispatchSize enum, %d\n",
|
||||
kernelDescriptor.kernelMetadata.kernelName.c_str(),
|
||||
kernelDescriptor.kernelAttributes.numGrfRequired,
|
||||
@@ -384,7 +384,7 @@ void EncodeDispatchKernel<Family>::encode(CommandContainer &container, EncodeDis
|
||||
|
||||
PreemptionHelper::applyPreemptionWaCmdsEnd<Family>(listCmdBufferStream, *args.device);
|
||||
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::DebugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::AfterWorkload)) {
|
||||
if (NEO::PauseOnGpuProperties::pauseModeAllowed(NEO::debugManager.flags.PauseOnEnqueue.get(), args.device->debugExecutionCounter.load(), NEO::PauseOnGpuProperties::PauseMode::AfterWorkload)) {
|
||||
void *commandBuffer = listCmdBufferStream->getSpace(MemorySynchronizationCommands<Family>::getSizeForBarrierWithPostSyncOperation(rootDeviceEnvironment, false));
|
||||
args.additionalCommands->push_back(commandBuffer);
|
||||
|
||||
@@ -404,8 +404,8 @@ inline void EncodeDispatchKernel<Family>::setupPostSyncMocs(WalkerType &walkerCm
|
||||
postSyncData.setMocs(gmmHelper->getMOCS(GMM_RESOURCE_USAGE_OCL_BUFFER));
|
||||
}
|
||||
|
||||
if (DebugManager.flags.OverridePostSyncMocs.get() != -1) {
|
||||
postSyncData.setMocs(DebugManager.flags.OverridePostSyncMocs.get());
|
||||
if (debugManager.flags.OverridePostSyncMocs.get() != -1) {
|
||||
postSyncData.setMocs(debugManager.flags.OverridePostSyncMocs.get());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -420,8 +420,8 @@ bool EncodeDispatchKernel<Family>::isRuntimeLocalIdsGenerationRequired(uint32_t
|
||||
return true;
|
||||
}
|
||||
bool hwGenerationOfLocalIdsEnabled = true;
|
||||
if (DebugManager.flags.EnableHwGenerationLocalIds.get() != -1) {
|
||||
hwGenerationOfLocalIdsEnabled = !!DebugManager.flags.EnableHwGenerationLocalIds.get();
|
||||
if (debugManager.flags.EnableHwGenerationLocalIds.get() != -1) {
|
||||
hwGenerationOfLocalIdsEnabled = !!debugManager.flags.EnableHwGenerationLocalIds.get();
|
||||
}
|
||||
if (hwGenerationOfLocalIdsEnabled) {
|
||||
if (activeChannels == 0) {
|
||||
@@ -521,8 +521,8 @@ void EncodeDispatchKernel<Family>::encodeThreadData(WALKER_TYPE &walkerCmd,
|
||||
|
||||
walkerCmd.setMessageSimd(walkerCmd.getSimdSize());
|
||||
|
||||
if (DebugManager.flags.ForceSimdMessageSizeInWalker.get() != -1) {
|
||||
walkerCmd.setMessageSimd(DebugManager.flags.ForceSimdMessageSizeInWalker.get());
|
||||
if (debugManager.flags.ForceSimdMessageSizeInWalker.get() != -1) {
|
||||
walkerCmd.setMessageSimd(debugManager.flags.ForceSimdMessageSizeInWalker.get());
|
||||
}
|
||||
|
||||
// 1) cross-thread inline data will be put into R1, but if kernel uses local ids, then cross-thread should be put further back
|
||||
@@ -686,7 +686,7 @@ void EncodeSurfaceState<Family>::encodeExtraBufferParams(EncodeSurfaceStateArgs
|
||||
}
|
||||
|
||||
if (surfaceState->getMemoryObjectControlState() == args.gmmHelper->getMOCS(GMM_RESOURCE_USAGE_OCL_BUFFER) &&
|
||||
DebugManager.flags.ForceL1Caching.get() != 0) {
|
||||
debugManager.flags.ForceL1Caching.get() != 0) {
|
||||
setConstCachePolicy = true;
|
||||
}
|
||||
|
||||
@@ -700,16 +700,16 @@ void EncodeSurfaceState<Family>::encodeExtraBufferParams(EncodeSurfaceStateArgs
|
||||
auto resourceFormat = gmm->gmmResourceInfo->getResourceFormat();
|
||||
compressionFormat = args.gmmHelper->getClientContext()->getSurfaceStateCompressionFormat(resourceFormat);
|
||||
|
||||
if (DebugManager.flags.ForceBufferCompressionFormat.get() != -1) {
|
||||
compressionFormat = DebugManager.flags.ForceBufferCompressionFormat.get();
|
||||
if (debugManager.flags.ForceBufferCompressionFormat.get() != -1) {
|
||||
compressionFormat = debugManager.flags.ForceBufferCompressionFormat.get();
|
||||
}
|
||||
}
|
||||
|
||||
if (DebugManager.flags.EnableStatelessCompressionWithUnifiedMemory.get()) {
|
||||
if (debugManager.flags.EnableStatelessCompressionWithUnifiedMemory.get()) {
|
||||
if (args.allocation && !MemoryPoolHelper::isSystemMemoryPool(args.allocation->getMemoryPool())) {
|
||||
setCoherencyType(surfaceState, R_SURFACE_STATE::COHERENCY_TYPE_GPU_COHERENT);
|
||||
setBufferAuxParamsForCCS(surfaceState);
|
||||
compressionFormat = DebugManager.flags.FormatForStatelessCompressionWithUnifiedMemory.get();
|
||||
compressionFormat = debugManager.flags.FormatForStatelessCompressionWithUnifiedMemory.get();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -25,8 +25,8 @@ void EncodeSurfaceState<Family>::appendImageCompressionParams(R_SURFACE_STATE *s
|
||||
}
|
||||
|
||||
if (imageFromBuffer) {
|
||||
if (DebugManager.flags.ForceBufferCompressionFormat.get() != -1) {
|
||||
compressionFormat = DebugManager.flags.ForceBufferCompressionFormat.get();
|
||||
if (debugManager.flags.ForceBufferCompressionFormat.get() != -1) {
|
||||
compressionFormat = debugManager.flags.ForceBufferCompressionFormat.get();
|
||||
}
|
||||
appendParamsForImageFromBuffer(surfaceState);
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@ namespace NEO {
|
||||
|
||||
bool ImplicitScalingHelper::isImplicitScalingEnabled(const DeviceBitfield &devices, bool preCondition) {
|
||||
bool apiSupport = ImplicitScaling::apiSupport;
|
||||
int32_t overrideEnableImplicitScaling = DebugManager.flags.EnableImplicitScaling.get();
|
||||
int32_t overrideEnableImplicitScaling = debugManager.flags.EnableImplicitScaling.get();
|
||||
if (overrideEnableImplicitScaling != -1) {
|
||||
apiSupport = !!overrideEnableImplicitScaling;
|
||||
preCondition = apiSupport;
|
||||
@@ -25,8 +25,8 @@ bool ImplicitScalingHelper::isImplicitScalingEnabled(const DeviceBitfield &devic
|
||||
preCondition &&
|
||||
apiSupport;
|
||||
|
||||
if (DebugManager.flags.EnableWalkerPartition.get() != -1) {
|
||||
partitionWalker = !!DebugManager.flags.EnableWalkerPartition.get();
|
||||
if (debugManager.flags.EnableWalkerPartition.get() != -1) {
|
||||
partitionWalker = !!debugManager.flags.EnableWalkerPartition.get();
|
||||
}
|
||||
// we can't do this without local memory
|
||||
partitionWalker &= OSInterface::osEnableLocalMemory;
|
||||
@@ -36,7 +36,7 @@ bool ImplicitScalingHelper::isImplicitScalingEnabled(const DeviceBitfield &devic
|
||||
|
||||
bool ImplicitScalingHelper::isSynchronizeBeforeExecutionRequired() {
|
||||
auto synchronizeBeforeExecution = false;
|
||||
int overrideSynchronizeBeforeExecution = DebugManager.flags.SynchronizeWalkerInWparidMode.get();
|
||||
int overrideSynchronizeBeforeExecution = debugManager.flags.SynchronizeWalkerInWparidMode.get();
|
||||
if (overrideSynchronizeBeforeExecution != -1) {
|
||||
synchronizeBeforeExecution = !!overrideSynchronizeBeforeExecution;
|
||||
}
|
||||
@@ -45,7 +45,7 @@ bool ImplicitScalingHelper::isSynchronizeBeforeExecutionRequired() {
|
||||
|
||||
bool ImplicitScalingHelper::isSemaphoreProgrammingRequired() {
|
||||
auto semaphoreProgrammingRequired = false;
|
||||
int overrideSemaphoreProgrammingRequired = DebugManager.flags.SynchronizeWithSemaphores.get();
|
||||
int overrideSemaphoreProgrammingRequired = debugManager.flags.SynchronizeWithSemaphores.get();
|
||||
if (overrideSemaphoreProgrammingRequired != -1) {
|
||||
semaphoreProgrammingRequired = !!overrideSemaphoreProgrammingRequired;
|
||||
}
|
||||
@@ -54,7 +54,7 @@ bool ImplicitScalingHelper::isSemaphoreProgrammingRequired() {
|
||||
|
||||
bool ImplicitScalingHelper::isCrossTileAtomicRequired(bool defaultCrossTileRequirement) {
|
||||
auto crossTileAtomicSynchronization = defaultCrossTileRequirement;
|
||||
int overrideCrossTileAtomicSynchronization = DebugManager.flags.UseCrossAtomicSynchronization.get();
|
||||
int overrideCrossTileAtomicSynchronization = debugManager.flags.UseCrossAtomicSynchronization.get();
|
||||
if (overrideCrossTileAtomicSynchronization != -1) {
|
||||
crossTileAtomicSynchronization = !!overrideCrossTileAtomicSynchronization;
|
||||
}
|
||||
@@ -63,7 +63,7 @@ bool ImplicitScalingHelper::isCrossTileAtomicRequired(bool defaultCrossTileRequi
|
||||
|
||||
bool ImplicitScalingHelper::isAtomicsUsedForSelfCleanup() {
|
||||
bool useAtomics = false;
|
||||
int overrideUseAtomics = DebugManager.flags.UseAtomicsForSelfCleanupSection.get();
|
||||
int overrideUseAtomics = debugManager.flags.UseAtomicsForSelfCleanupSection.get();
|
||||
if (overrideUseAtomics != -1) {
|
||||
useAtomics = !!(overrideUseAtomics);
|
||||
}
|
||||
@@ -76,7 +76,7 @@ bool ImplicitScalingHelper::isSelfCleanupRequired(const WalkerPartition::WalkerP
|
||||
args.synchronizeBeforeExecution ||
|
||||
!args.staticPartitioning);
|
||||
|
||||
int overrideProgramSelfCleanup = DebugManager.flags.ProgramWalkerPartitionSelfCleanup.get();
|
||||
int overrideProgramSelfCleanup = debugManager.flags.ProgramWalkerPartitionSelfCleanup.get();
|
||||
if (overrideProgramSelfCleanup != -1) {
|
||||
defaultSelfCleanup = !!(overrideProgramSelfCleanup);
|
||||
}
|
||||
@@ -85,7 +85,7 @@ bool ImplicitScalingHelper::isSelfCleanupRequired(const WalkerPartition::WalkerP
|
||||
|
||||
bool ImplicitScalingHelper::isWparidRegisterInitializationRequired() {
|
||||
bool initWparidRegister = false;
|
||||
int overrideInitWparidRegister = DebugManager.flags.WparidRegisterProgramming.get();
|
||||
int overrideInitWparidRegister = debugManager.flags.WparidRegisterProgramming.get();
|
||||
if (overrideInitWparidRegister != -1) {
|
||||
initWparidRegister = !!(overrideInitWparidRegister);
|
||||
}
|
||||
@@ -93,7 +93,7 @@ bool ImplicitScalingHelper::isWparidRegisterInitializationRequired() {
|
||||
}
|
||||
|
||||
bool ImplicitScalingHelper::isPipeControlStallRequired(bool defaultEmitPipeControl) {
|
||||
int overrideUsePipeControl = DebugManager.flags.UsePipeControlAfterPartitionedWalker.get();
|
||||
int overrideUsePipeControl = debugManager.flags.UsePipeControlAfterPartitionedWalker.get();
|
||||
if (overrideUsePipeControl != -1) {
|
||||
defaultEmitPipeControl = !!(overrideUsePipeControl);
|
||||
}
|
||||
@@ -101,7 +101,7 @@ bool ImplicitScalingHelper::isPipeControlStallRequired(bool defaultEmitPipeContr
|
||||
}
|
||||
|
||||
bool ImplicitScalingHelper::pipeControlBeforeCleanupAtomicSyncRequired() {
|
||||
int overrideUsePipeControl = DebugManager.flags.ProgramStallCommandForSelfCleanup.get();
|
||||
int overrideUsePipeControl = debugManager.flags.ProgramStallCommandForSelfCleanup.get();
|
||||
if (overrideUsePipeControl != -1) {
|
||||
return !!(overrideUsePipeControl);
|
||||
}
|
||||
|
||||
@@ -132,8 +132,8 @@ void ImplicitScalingDispatch<GfxFamily>::dispatchCommands(LinearStream &commandS
|
||||
args,
|
||||
hwInfo);
|
||||
} else {
|
||||
if (DebugManager.flags.ExperimentalSetWalkerPartitionCount.get()) {
|
||||
partitionCount = DebugManager.flags.ExperimentalSetWalkerPartitionCount.get();
|
||||
if (debugManager.flags.ExperimentalSetWalkerPartitionCount.get()) {
|
||||
partitionCount = debugManager.flags.ExperimentalSetWalkerPartitionCount.get();
|
||||
if (partitionCount == 1u) {
|
||||
walkerCmd.setPartitionType(WalkerType::PARTITION_TYPE::PARTITION_TYPE_DISABLED);
|
||||
}
|
||||
|
||||
@@ -91,8 +91,8 @@ uint32_t computePartitionCountAndPartitionType(uint32_t preferredMinimalPartitio
|
||||
size_t workgroupCount = 0u;
|
||||
bool disablePartitionForPartitionCountOne{};
|
||||
|
||||
if (NEO::DebugManager.flags.ExperimentalSetWalkerPartitionType.get() != -1) {
|
||||
requestedPartitionType = static_cast<PARTITION_TYPE>(NEO::DebugManager.flags.ExperimentalSetWalkerPartitionType.get());
|
||||
if (NEO::debugManager.flags.ExperimentalSetWalkerPartitionType.get() != -1) {
|
||||
requestedPartitionType = static_cast<PARTITION_TYPE>(NEO::debugManager.flags.ExperimentalSetWalkerPartitionType.get());
|
||||
}
|
||||
|
||||
if (requestedPartitionType.has_value()) {
|
||||
@@ -115,8 +115,8 @@ uint32_t computePartitionCountAndPartitionType(uint32_t preferredMinimalPartitio
|
||||
const size_t maxDimension = std::max({groupCount.z, groupCount.y, groupCount.x});
|
||||
|
||||
auto goWithMaxAlgorithm = !preferStaticPartitioning;
|
||||
if (NEO::DebugManager.flags.WalkerPartitionPreferHighestDimension.get() != -1) {
|
||||
goWithMaxAlgorithm = !!!NEO::DebugManager.flags.WalkerPartitionPreferHighestDimension.get();
|
||||
if (NEO::debugManager.flags.WalkerPartitionPreferHighestDimension.get() != -1) {
|
||||
goWithMaxAlgorithm = !!!NEO::debugManager.flags.WalkerPartitionPreferHighestDimension.get();
|
||||
}
|
||||
|
||||
// compute misaligned %, accept imbalance below threshold in favor of Z/Y/X distribution.
|
||||
@@ -161,10 +161,10 @@ uint32_t computePartitionCountAndPartitionType(uint32_t preferredMinimalPartitio
|
||||
// Dynamic partitioning - compute optimal partition count
|
||||
size_t partitionCount = std::min(static_cast<size_t>(16u), workgroupCount);
|
||||
partitionCount = Math::prevPowerOfTwo(partitionCount);
|
||||
if (NEO::DebugManager.flags.SetMinimalPartitionSize.get() != 0) {
|
||||
const auto workgroupPerPartitionThreshold = NEO::DebugManager.flags.SetMinimalPartitionSize.get() == -1
|
||||
if (NEO::debugManager.flags.SetMinimalPartitionSize.get() != 0) {
|
||||
const auto workgroupPerPartitionThreshold = NEO::debugManager.flags.SetMinimalPartitionSize.get() == -1
|
||||
? 512u
|
||||
: static_cast<unsigned>(NEO::DebugManager.flags.SetMinimalPartitionSize.get());
|
||||
: static_cast<unsigned>(NEO::debugManager.flags.SetMinimalPartitionSize.get());
|
||||
preferredMinimalPartitionCount = std::max(2u, preferredMinimalPartitionCount);
|
||||
|
||||
while (partitionCount > preferredMinimalPartitionCount) {
|
||||
|
||||
Reference in New Issue
Block a user