[llvm-branch-commits] [flang] [llvm] [mlir] [MLIR][Flang][OpenMP] Make omp.simdloop into a loop wrapper (PR #87365)

Krzysztof Parzyszek via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Wed Apr 10 12:03:33 PDT 2024


================
@@ -521,7 +521,7 @@ struct OpWithBodyGenInfo {
 /// \param [in]   op - the operation the body belongs to.
 /// \param [in] info - options controlling code-gen for the construction.
 template <typename Op>
-static void createBodyOfOp(Op &op, OpWithBodyGenInfo &info) {
+static void createBodyOfOp(mlir::Operation &op, OpWithBodyGenInfo &info) {
----------------
kparzysz wrote:

The new version doesn't take any parameters or return any values with the type in the template arguments, so there is no compelling reason to keep it as a template, expecially given its size.

I suggest converting it to a non-template, with an extra parameter "isLoop" passed from outside.  We can have "is_loop" trait to make it easy.

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


More information about the llvm-branch-commits mailing list