[flang-commits] [flang] [mlir] [MLIR][OpenMP] Improve assemblyFormat handling for clause-based ops (PR #108023)

Sergio Afonso via flang-commits flang-commits at lists.llvm.org
Wed Sep 11 03:05:19 PDT 2024


================
@@ -59,26 +59,21 @@ def OpenMP_MapBoundsType : OpenMP_Type<"MapBounds", "map_bounds_ty"> {
 // Optionally, operation traits and extra class declarations might be attached
 // to clauses, which will be forwarded to all operations that include them.
 //
-// Each clause must specify whether it's required or optional. This impacts how
-// the `assemblyFormat` for operations including it get generated.
-//
 // An `OpenMP_Op` can inhibit the inheritance of `traits`, `arguments`,
-// `assemblyFormat`, `description` and `extraClassDeclaration` fields from any
-// given `OpenMP_Clause` by setting to 1 the corresponding "skip" template
-// argument bit.
-class OpenMP_Clause<bit isRequired, bit skipTraits, bit skipArguments,
-                    bit skipAssemblyFormat, bit skipDescription,
-                    bit skipExtraClassDeclaration> {
-  bit required = isRequired;
-
+// `{opt,req}assemblyFormat`, `description` and `extraClassDeclaration` fields
+// from any given `OpenMP_Clause` by setting to 1 the corresponding "skip"
+// template argument bit.
+class OpenMP_Clause<bit skipTraits, bit skipArguments, bit skipAssemblyFormat,
----------------
skatrak wrote:

Good point, I'll update the comment above

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


More information about the flang-commits mailing list