Skip to content

Commit eb4d01c

Browse files
sys-igcigcbot
authored andcommitted
[Autobackout][FunctionalRegression]Revert of change: 6399a00: XE2 compiles to SIMD16 in case of spilling
XE2 compilation goes to SIMD16 route if we have spills during SIMD32 compilation. Test added & previous one that covered for kernels that exhaust PTSS changed.
1 parent 3218302 commit eb4d01c

File tree

2 files changed

+3
-23
lines changed

2 files changed

+3
-23
lines changed

IGC/Compiler/CISACodeGen/OpenCLKernelCodeGen.cpp

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3443,8 +3443,7 @@ namespace IGC
34433443

34443444
if (ctx->platform.getMinDispatchMode() == SIMDMode::SIMD16)
34453445
{
3446-
bool abortOnSpills = ctx->platform.isCoreXE2() && (ctx->getModuleMetaData()->csInfo.forcedSIMDSize != 32);
3447-
AddCodeGenPasses(*ctx, shaders, Passes, SIMDMode::SIMD32, abortOnSpills);
3446+
AddCodeGenPasses(*ctx, shaders, Passes, SIMDMode::SIMD32, false);
34483447
AddCodeGenPasses(*ctx, shaders, Passes, SIMDMode::SIMD16, false);
34493448

34503449
ctx->SetSIMDInfo(SIMD_SKIP_HW, SIMDMode::SIMD8, ShaderDispatchMode::NOT_APPLICABLE);
@@ -3749,24 +3748,9 @@ namespace IGC
37493748
return SIMDStatus::SIMD_FUNC_FAIL;
37503749
}
37513750

3751+
EP.m_canAbortOnSpill = false; // spill is always allowed since we don't do SIMD size lowering
37523752
// Next we check if there is a required sub group size specified
37533753
CodeGenContext* pCtx = GetContext();
3754-
3755-
CShader* simd16Program = m_parent->GetShader(SIMDMode::SIMD16);
3756-
CShader* simd32Program = m_parent->GetShader(SIMDMode::SIMD32);
3757-
3758-
EP.m_canAbortOnSpill = false || pCtx->platform.isCoreXE2();
3759-
bool compileFunctionVariants = pCtx->m_enableSimdVariantCompilation &&
3760-
(m_FGA && IGC::isIntelSymbolTableVoidProgram(m_FGA->getGroupHead(&F)));
3761-
3762-
if((simd16Program && simd16Program->ProgramOutput()->m_programSize > 0) ||
3763-
(simd32Program && simd32Program->ProgramOutput()->m_programSize > 0))
3764-
{
3765-
bool canCompileMultipleSIMD = compileFunctionVariants;
3766-
if (!(canCompileMultipleSIMD && (pCtx->getModuleMetaData()->csInfo.forcedSIMDSize == 0)))
3767-
return SIMDStatus::SIMD_FUNC_FAIL;
3768-
}
3769-
37703754
MetaDataUtils* pMdUtils = EP.getAnalysis<MetaDataUtilsWrapper>().getMetaDataUtils();
37713755
FunctionInfoMetaDataHandle funcInfoMD = pMdUtils->getFunctionsInfoItem(&F);
37723756
uint32_t simd_size = getReqdSubGroupSize(F, pMdUtils);
@@ -3869,7 +3853,7 @@ namespace IGC
38693853
return SIMDStatus::SIMD_PASS;
38703854
}
38713855

3872-
if (simdMode == SIMDMode::SIMD16 && !pCtx->platform.isCoreXE2() && !hasSubGroupForce && !forceLowestSIMDForStackCalls && !hasSubroutine)
3856+
if (simdMode == SIMDMode::SIMD16 && !hasSubGroupForce && !forceLowestSIMDForStackCalls && !hasSubroutine)
38733857
{
38743858
pCtx->SetSIMDInfo(SIMD_SKIP_PERF, simdMode, ShaderDispatchMode::NOT_APPLICABLE);
38753859
return SIMDStatus::SIMD_FUNC_FAIL;

IGC/Compiler/CISACodeGen/Platform.hpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -203,10 +203,6 @@ bool isProductChildOf(PRODUCT_FAMILY product) const
203203
return m_platformInfo.eProductFamily >= product;
204204
}
205205

206-
bool isCoreXE2() const {
207-
return ( m_platformInfo.eRenderCoreFamily == IGFX_XE2_HPG_CORE );
208-
}
209-
210206
// This function checks if core is child of another core
211207
bool isCoreChildOf(GFXCORE_FAMILY core) const
212208
{

0 commit comments

Comments
 (0)