llvm-project/mlir/test/mlir-pdll
Markus Böck 9f186bb125 [mlir][ods] Make Type- and AttrInterfaces also `Type`s and `Attr`s
By making TypeInterfaces and AttrInterfaces, Types and Attrs respectively it'd then be possible to use them anywhere where a Type or Attr may go. That is within the arguments and results of an Op definition, in a RewritePattern etc.

Prior to this change users had to separately define a Type or Attr, with a predicate to check whether a type or attribute implements a given interface. Such code will be redundant now.
Removing such occurrences in upstream dialects will be part of a separate patch.

As part of implementing this patch, slight refactoring had to be done. In particular, Interfaces cppClassName field was renamed to cppInterfaceName as it "clashed" with TypeConstraints cppClassName. In particular Interfaces cppClassName expected just the class name, without any namespaces, while TypeConstraints cppClassName expected a fully qualified class name.

Differential Revision: https://reviews.llvm.org/D129209
2022-07-07 11:54:47 +02:00
..
CodeGen [mlir:PDLL] Rework the C++ generation of native Constraint/Rewrite arguments and results 2022-05-30 17:35:34 -07:00
Integration [mlir:PDLL] Fix the import of native constraints from ODS 2022-04-28 12:58:00 -07:00
Parser [mlir][ods] Make Type- and AttrInterfaces also `Type`s and `Attr`s 2022-07-07 11:54:47 +02:00
lit.local.cfg [mlir:PDLL] Add support for PDL MLIR code generation 2022-02-26 11:08:51 -08:00