[llvm-branch-commits] [flang] [llvm] [Flang][OpenMP] Prevent re-composition of composite constructs (PR #102613)
Krzysztof Parzyszek via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Fri Aug 9 06:18:03 PDT 2024
================
@@ -2263,24 +2321,13 @@ static void genOMPDispatch(lower::AbstractConverter &converter,
// Composite constructs
case llvm::omp::Directive::OMPD_distribute_parallel_do:
- genCompositeDistributeParallelDo(converter, symTable, semaCtx, eval, loc,
- queue, item, *loopDsp);
- break;
case llvm::omp::Directive::OMPD_distribute_parallel_do_simd:
- genCompositeDistributeParallelDoSimd(converter, symTable, semaCtx, eval,
- loc, queue, item, *loopDsp);
- break;
case llvm::omp::Directive::OMPD_distribute_simd:
- genCompositeDistributeSimd(converter, symTable, semaCtx, eval, loc, queue,
- item, *loopDsp);
- break;
case llvm::omp::Directive::OMPD_do_simd:
- genCompositeDoSimd(converter, symTable, semaCtx, eval, loc, queue, item,
- *loopDsp);
- break;
case llvm::omp::Directive::OMPD_taskloop_simd:
- genCompositeTaskloopSimd(converter, symTable, semaCtx, eval, loc, queue,
- item, *loopDsp);
+ // Composite constructs should have been split into a sequence of leaf
+ // constructs and lowered by genOMPCompositeDispatch().
+ llvm_unreachable("Unexpected composite construct.");
break;
default:
----------------
kparzysz wrote:
Maybe you could delete the specific cases with composite constructs, and add `assert(!isCompositeConstruct(dir))` to the default label.
https://github.com/llvm/llvm-project/pull/102613
More information about the llvm-branch-commits
mailing list