[flang-commits] [flang] [llvm] [mlir] [flang][OpenMP] Enable tiling (PR #143715)
Michael Kruse via flang-commits
flang-commits at lists.llvm.org
Tue Aug 26 05:15:58 PDT 2025
================
@@ -3449,13 +3500,9 @@ static void genOMPDispatch(lower::AbstractConverter &converter,
newOp = genTeamsOp(converter, symTable, stmtCtx, semaCtx, eval, loc, queue,
item);
break;
- case llvm::omp::Directive::OMPD_tile: {
- unsigned version = semaCtx.langOptions().OpenMPVersion;
- if (!semaCtx.langOptions().OpenMPSimd)
- TODO(loc, "Unhandled loop directive (" +
- llvm::omp::getOpenMPDirectiveName(dir, version) + ")");
+ case llvm::omp::Directive::OMPD_tile:
+ newOp = genLoopOp(converter, symTable, semaCtx, eval, loc, queue, item);
----------------
Meinersbur wrote:
> In the GenericLoopConversionPass there is a function rewriteStandaloneLoop that converts the loop to a simdloop.
I think the semantics are different. Independent of how it is executed (parallel, simd, sequential, ...), the loop is duplicated with a copy nested in the other. This logically results in $n^2$ executions, where $n$ is the tripcount of the original loop.
I was experimenting with it, and could observe those additional executions.
https://github.com/llvm/llvm-project/pull/143715
More information about the flang-commits
mailing list