[all-commits] [llvm/llvm-project] e865fa: [TableGen] Add a library-based entry point for par...
River Riddle via All-commits
all-commits at lists.llvm.org
Thu Mar 3 16:14:33 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: e865fa75308aa8dc103ed2ac559e678b5531fa30
https://github.com/llvm/llvm-project/commit/e865fa75308aa8dc103ed2ac559e678b5531fa30
Author: River Riddle <riddleriver at gmail.com>
Date: 2022-03-03 (Thu, 03 Mar 2022)
Changed paths:
A llvm/include/llvm/TableGen/Parser.h
M llvm/lib/TableGen/CMakeLists.txt
A llvm/lib/TableGen/Parser.cpp
M llvm/lib/TableGen/Record.cpp
A llvm/lib/TableGen/RecordContext.h
M llvm/unittests/TableGen/CMakeLists.txt
A llvm/unittests/TableGen/ParserEntryPointTest.cpp
Log Message:
-----------
[TableGen] Add a library-based entry point for parsing td files
This commit adds a new `TableGenParseFile` entry point for tablegen
that parses an input buffer and invokes a callback function with
a record keeper (notably without an output buffer). This kind of entry
point is very useful for tablegen consuming tools that don't create
output, and want invoke tablegen multiple times. The current way
that we interact with tablegen is via relative includes to
TGParser(not great).
Differential Revision: https://reviews.llvm.org/D119899
Commit: 81f2f4dfb2922e4f7af8bbfd8b653eda7c1f1339
https://github.com/llvm/llvm-project/commit/81f2f4dfb2922e4f7af8bbfd8b653eda7c1f1339
Author: River Riddle <riddleriver at gmail.com>
Date: 2022-03-03 (Thu, 03 Mar 2022)
Changed paths:
M llvm/include/llvm/Support/SourceMgr.h
M llvm/lib/Support/SourceMgr.cpp
M mlir/include/mlir/IR/OpBase.td
M mlir/include/mlir/TableGen/Constraint.h
M mlir/include/mlir/Tools/PDLL/AST/Context.h
A mlir/include/mlir/Tools/PDLL/ODS/Constraint.h
A mlir/include/mlir/Tools/PDLL/ODS/Context.h
A mlir/include/mlir/Tools/PDLL/ODS/Dialect.h
A mlir/include/mlir/Tools/PDLL/ODS/Operation.h
M mlir/lib/TableGen/Constraint.cpp
M mlir/lib/Tools/PDLL/AST/CMakeLists.txt
M mlir/lib/Tools/PDLL/AST/Context.cpp
M mlir/lib/Tools/PDLL/CMakeLists.txt
M mlir/lib/Tools/PDLL/CodeGen/MLIRGen.cpp
A mlir/lib/Tools/PDLL/ODS/CMakeLists.txt
A mlir/lib/Tools/PDLL/ODS/Context.cpp
A mlir/lib/Tools/PDLL/ODS/Dialect.cpp
A mlir/lib/Tools/PDLL/ODS/Operation.cpp
M mlir/lib/Tools/PDLL/Parser/CMakeLists.txt
M mlir/lib/Tools/PDLL/Parser/Parser.cpp
M mlir/test/mlir-pdll/CodeGen/MLIR/expr.pdll
A mlir/test/mlir-pdll/CodeGen/MLIR/include/ops.td
M mlir/test/mlir-pdll/Parser/directive-failure.pdll
M mlir/test/mlir-pdll/Parser/expr-failure.pdll
M mlir/test/mlir-pdll/Parser/expr.pdll
A mlir/test/mlir-pdll/Parser/include/interfaces.td
A mlir/test/mlir-pdll/Parser/include/ops.td
A mlir/test/mlir-pdll/Parser/include_td.pdll
M mlir/test/mlir-pdll/Parser/stmt-failure.pdll
M mlir/tools/mlir-pdll/mlir-pdll.cpp
Log Message:
-----------
[PDLL] Add support for tablegen includes and importing ODS information
This commit adds support for processing tablegen include files, and importing
various information from ODS. This includes operations, attribute+type constraints,
attribute/operation/type interfaces, etc. This will allow for much more robust tooling,
and also allows for referencing ODS constructs directly within PDLL (imported interfaces
can be used as constraints, operation result names can be used for member access, etc).
Differential Revision: https://reviews.llvm.org/D119900
Compare: https://github.com/llvm/llvm-project/compare/dd29597e103c...81f2f4dfb292
More information about the All-commits
mailing list