[Mlir-commits] [flang] [mlir] [Flang][OpenMP] Support lowering of simd reductions (PR #112194)

Sergio Afonso llvmlistbot at llvm.org
Tue Oct 15 05:36:45 PDT 2024


skatrak wrote:

> If you do not want to change for already implemented lowering, it is fine. But going forward we should try to error out in Flang vs translation.

What is the reason for this preference? In my opinion, it has the disadvantage that we wouldn't be able to independently work on Flang lowering before the translation to LLVM IR for that operation/clause is implemented.

I understand that we don't want to silently ignore clauses by lowering them to MLIR and then not taking them into account in the LLVM IR translation pass. But if we emit an error and return early when we find these operations/clauses there, the result from a user perspective would be the same. At the moment the error message is different, but if that's important it wouldn't take much to add a similar TODO macro to the MLIR to LLVM IR translation as well. Either way we should trigger errors there because if another dialect or frontend decides to introduce operations/clauses for which we have no translation to LLVM IR implemented, we should emit errors instead of crashing/ignoring them.

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


More information about the Mlir-commits mailing list