MLIR 22.0.0git
mlir::pdll Namespace Reference

Namespaces

namespace  ast
namespace  ods

Classes

class  CodeCompleteContext
 This class provides an abstract interface into the parser for hooking in code completion events. More...
class  Lexer
class  Token

Functions

void codegenPDLLToCPP (const ast::Module &astModule, ModuleOp module, raw_ostream &os)
OwningOpRef< ModuleOp > codegenPDLLToMLIR (MLIRContext *mlirContext, const ast::Context &context, const llvm::SourceMgr &sourceMgr, const ast::Module &module)
 Given a PDLL module, generate an MLIR PDL pattern module within the given MLIR context.
FailureOr< ast::Module * > parsePDLLAST (ast::Context &ctx, llvm::SourceMgr &sourceMgr, bool enableDocumentation=false, CodeCompleteContext *codeCompleteContext=nullptr)
 Parse an AST module from the main file of the given source manager.

Function Documentation

◆ codegenPDLLToCPP()

void mlir::pdll::codegenPDLLToCPP ( const ast::Module & astModule,
ModuleOp module,
raw_ostream & os )

Definition at line 246 of file CPPGen.cpp.

◆ codegenPDLLToMLIR()

OwningOpRef< ModuleOp > mlir::pdll::codegenPDLLToMLIR ( MLIRContext * mlirContext,
const ast::Context & context,
const llvm::SourceMgr & sourceMgr,
const ast::Module & module )

Given a PDLL module, generate an MLIR PDL pattern module within the given MLIR context.

Definition at line 624 of file MLIRGen.cpp.

References mlir::verify().

◆ parsePDLLAST()

FailureOr< ast::Module * > mlir::pdll::parsePDLLAST ( ast::Context & ctx,
llvm::SourceMgr & sourceMgr,
bool enableDocumentation = false,
CodeCompleteContext * codeCompleteContext = nullptr )

Parse an AST module from the main file of the given source manager.

enableDocumentation is an optional flag that, when set, indicates that the parser should also include documentation when building the AST when possible. codeCompleteContext is an optional code completion context that may be provided to receive code completion suggestions. If a completion is hit, this method returns a failure.

Definition at line 3205 of file Parser.cpp.