|
picceler
|
MLIR code generator that converts AST nodes to MLIR constructs. This offers the initial IR generation from the AST. More...
#include <mlir_gen.h>
Public Types | |
| using | GeneratorFunction = std::function<mlir::Value(mlir::Location, const std::vector<mlir::Value> &)> |
| using | VariableTable = std::unordered_map<std::string, mlir::Value> |
| using | NamedVariableTable = std::pair<std::string, VariableTable> |
Public Member Functions | |
| MLIRGen ()=delete | |
| MLIRGen (mlir::MLIRContext *context) | |
| MLIRGen (const MLIRGen &)=default | |
| MLIRGen & | operator= (const MLIRGen &)=default |
| MLIRGen (MLIRGen &&)=default | |
| MLIRGen & | operator= (MLIRGen &&)=default |
| ~MLIRGen () noexcept | |
| mlir::ModuleOp | generate (ModuleNode *root, const std::string &sourceFile) |
| Generates MLIR code from the given AST root node. | |
MLIR code generator that converts AST nodes to MLIR constructs. This offers the initial IR generation from the AST.
| using picceler::MLIRGen::GeneratorFunction = std::function<mlir::Value(mlir::Location, const std::vector<mlir::Value> &)> |
| using picceler::MLIRGen::NamedVariableTable = std::pair<std::string, VariableTable> |
| using picceler::MLIRGen::VariableTable = std::unordered_map<std::string, mlir::Value> |
|
delete |
| picceler::MLIRGen::MLIRGen | ( | mlir::MLIRContext * | context | ) |
|
default |
|
default |
|
noexcept |
| mlir::ModuleOp picceler::MLIRGen::generate | ( | ModuleNode * | root, |
| const std::string & | sourceFile ) |
Generates MLIR code from the given AST root node.
| root | The root node of the AST. |
| sourceFile | The source file name for location tracking. |