File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -227,11 +227,6 @@ bool EmitPass::setCurrentShader(llvm::Function* F)
227
227
{
228
228
return false;
229
229
}
230
- // Only simd8 will be tried when there are subroutines in this group.
231
- if (m_SimdMode != SIMDMode::SIMD8 && !FG->isSingle())
232
- {
233
- return false;
234
- }
235
230
Kernel = FG->getHead();
236
231
}
237
232
else
@@ -350,6 +345,15 @@ bool EmitPass::runOnFunction(llvm::Function& F)
350
345
return false;
351
346
}
352
347
348
+ // If max work group size is set, we need to compile for all requested SIMD modes.
349
+ // Otherwise, only compile simd8 for subroutines
350
+ if (ctx->getModuleMetaData()->csInfo.maxWorkGroupSize == 0 &&
351
+ m_FGA && !m_FGA->getGroup(&F)->isSingle() &&
352
+ m_SimdMode != SIMDMode::SIMD8)
353
+ {
354
+ return false;
355
+ }
356
+
353
357
bool isCloned = false;
354
358
if (DebugInfoData::hasDebugInfo(m_currShader))
355
359
{
You can’t perform that action at this time.
0 commit comments