Contribute a grammar, along with associated tests, from the upstream project maintained at https://github.com/artagnon/tree-sitter-mlir. The new grammar includes several fixes, and successfully parses 60-80% of MLIR tests in the Arith, Math, ControlFlow, SCF, Tensor, Affine, and Linalg dialects. Differential Revision: https://reviews.llvm.org/D144408
454 B
454 B
tree-sitter-mlir
tree-sitter grammar for MLIR following the lang-ref. The parser is incomplete, and the bench statistics on the test files in the MLIR tree are as follows:
Math, 100% passed
Builtin, 100% passed
Func, 100% passed
ControlFlow, 100% passed
Tensor, 93.33% passed
Arith, 83.33% passed
SCF, 88% passed
Affine, 73.08% passed
Linalg, 51.11% passed