Skip to content

Commit ee7a6a0

Browse files
iwwuigcbot
authored andcommitted
Add regkey to control loosenSimd32occu result
- Regkey ForceLoosenSimd32Occu default 2 to use platform specific implementation. Value 0 & 1 will force the value.
1 parent e30ad65 commit ee7a6a0

File tree

3 files changed

+12
-7
lines changed

3 files changed

+12
-7
lines changed

IGC/Compiler/CISACodeGen/Platform.hpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -667,7 +667,10 @@ bool supportDynamicBTIsAllocation() const
667667

668668
bool loosenSimd32occu() const
669669
{
670-
return (m_platformInfo.eRenderCoreFamily >= IGFX_GEN12_CORE && m_platformInfo.eProductFamily != IGFX_DG2);
670+
if (IGC_GET_FLAG_VALUE(ForceLoosenSimd32Occu) == 2)
671+
return (m_platformInfo.eRenderCoreFamily >= IGFX_GEN12_CORE && m_platformInfo.eProductFamily != IGFX_DG2);
672+
else
673+
return IGC_GET_FLAG_VALUE(ForceLoosenSimd32Occu);
671674
}
672675

673676
// Local memory here refers to memory on the device- e.g. HBM for PVC.

IGC/common/MDFrameWork.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -439,6 +439,7 @@ namespace IGC
439439
bool DisableFDivToFMulInvOpt = false;
440440
bool initializePhiSampleSourceWA = false;
441441
bool WaDisableSubspanUseNoMaskForCB = false;
442+
bool DisableLoosenSimd32Occu = false;
442443

443444
unsigned FastestS1Options = 0; // FCEXP_NO_EXPRIMENT. Can't access the enum here for some reason.
444445
};

IGC/common/igc_flags.h

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -329,13 +329,14 @@ DECLARE_IGC_REGKEY(bool, ForceStatelessForQueueT, true, "In OCL, force to
329329
DECLARE_IGC_REGKEY(bool, ForceMemoryFenceBeforeEOT, false, "Forces inserting SLM or gloabal memory fence before EOT if shader writes to SLM or goblam memory respectively.", false)
330330
DECLARE_IGC_REGKEY(bool, EnableRTmaskPso, true, "Enable render target mask optimization in PSO opt", false)
331331
DECLARE_IGC_REGKEY(DWORD, MSAAClearedKernel, 0, "Insert the discard code for MSAA_MSC_Cleared kernels. 2/4/8/16", false)
332-
DECLARE_IGC_REGKEY(bool, EnablerReadSuppressionWA, true, "Enable read suppression WA for the send and indirect access", false)
333-
DECLARE_IGC_REGKEY(bool, EnableLSCFenceUGMBeforeEOT, true, "Enable inserting fence.ugm.06.tile before EOT if a kernel has any write to UGM [XeHPC, PVC].", true)
334-
DECLARE_IGC_REGKEY(bool, EnableRTLSCFenceUGMBeforeEOT, true, "[tmp]Enable inserting fence.ugm.06.tile before EOT for RT shader [XeHPC, PVC].", false)
335-
DECLARE_IGC_REGKEY(bool, manualEnableRSWA, false, "Enable read suppression WA for the send and indirect access", false)
336-
DECLARE_IGC_REGKEY(bool, DPASReadSuppressionWA, true, "Enable read suppression WA for the send and indirect access", false)
337-
DECLARE_IGC_REGKEY(bool, EnableDivergentBarrierCheck, false, "Uses WIAnalysis to find barriers in divergent flow control. May have false positives.", false)
332+
DECLARE_IGC_REGKEY(bool, EnablerReadSuppressionWA, true, "Enable read suppression WA for the send and indirect access", false)
333+
DECLARE_IGC_REGKEY(bool, EnableLSCFenceUGMBeforeEOT, true, "Enable inserting fence.ugm.06.tile before EOT if a kernel has any write to UGM [XeHPC, PVC].", true)
334+
DECLARE_IGC_REGKEY(bool, EnableRTLSCFenceUGMBeforeEOT, true, "[tmp]Enable inserting fence.ugm.06.tile before EOT for RT shader [XeHPC, PVC].", false)
335+
DECLARE_IGC_REGKEY(bool, manualEnableRSWA, false, "Enable read suppression WA for the send and indirect access", false)
336+
DECLARE_IGC_REGKEY(bool, DPASReadSuppressionWA, true, "Enable read suppression WA for the send and indirect access", false)
337+
DECLARE_IGC_REGKEY(bool, EnableDivergentBarrierCheck, false, "Uses WIAnalysis to find barriers in divergent flow control. May have false positives.", false)
338338
DECLARE_IGC_REGKEY(bool, EnableBitcastExtractInsertPattern, true, "Enable BitcastExtractInsertPattern in CustomSafeOptPass.", true)
339+
DECLARE_IGC_REGKEY(DWORD, ForceLoosenSimd32Occu, 2, "Control loosenSimd32occu return value. 0 - off, 1 - on, 2 - platform default", false)
339340

340341
DECLARE_IGC_GROUP("Shader dumping")
341342
DECLARE_IGC_REGKEY(bool, EnableCosDump, false, "Enable cos dump", true)

0 commit comments

Comments
 (0)