================
@@ -66,6 +66,15 @@ static bool canEmitGPUFusedDistSchedule(const CodeGenModule
&CGM,
!S.getSingleClause<OMPOrderedClause>();
}
+static bool canEmitGPUNoLoopKernel(CodeGenModule &CGM,
+ const OMPLoopDirective &S) {
+ const auto *D = dyn_cast<OMPTargetTeamsDistributeParallelForDirective>(&S);
+ return CGM.getLangOpts().OpenMPIRBuilder && S.getLoopsNumber() == 1 &&
----------------
nicebert wrote:
They're allowed to differ, that's deliberate. One says the kernel can be
launched with a no-loop sized grid, the other says we can actually drop the
loop. Dropping it currently goes through the same path as flang, so it needs
the IRBuilder, while the grid sizing doesn't.
https://github.com/llvm/llvm-project/pull/205325
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits