[llvm-branch-commits] [flang] [flang] Lower omp.workshare to other omp constructs (PR #101446)

Ivan R. Ivanov via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Tue Sep 10 00:31:23 PDT 2024


ivanradanov wrote:

@kiranchandramohan @tblah @skatrak I have a question to people more familiar with Fortran and the entire Flang pipeline - is it possible that we would have CFG (multiple blocks) in the IR generated in the workshare statement at this point in the pipeline (immediately after lowering HLFIR to FIR).

The transformation I implemented can work with CFG but the transformation _inlines_ the region contained in the `omp.workshare` region in its parent op (while transforming it), which means that the parent op would need to support multiple blocks, which is not a given (e.g. `fir.if`). Is there an operation like `scf.execute` which can be used here to inline the contents of the `omp.workshare` or should we not support CFG in this transformation.

https://github.com/llvm/llvm-project/pull/101446


More information about the llvm-branch-commits mailing list