MLIR
20.0.0git
|
This decl represents a user defined rewrite. More...
#include "mlir/Tools/PDLL/AST/Nodes.h"
Public Member Functions | |
const Name & | getName () const |
Return the name of the rewrite. More... | |
MutableArrayRef< VariableDecl * > | getInputs () |
Return the input arguments of this rewrite. More... | |
ArrayRef< VariableDecl * > | getInputs () const |
MutableArrayRef< VariableDecl * > | getResults () |
Return the explicit results of the rewrite declaration. More... | |
ArrayRef< VariableDecl * > | getResults () const |
std::optional< StringRef > | getCodeBlock () const |
Return the optional code block of this rewrite, if this is a native rewrite with a provided implementation. More... | |
const CompoundStmt * | getBody () const |
Return the body of this rewrite if this rewrite is a PDLL rewrite, otherwise returns nullptr. More... | |
Type | getResultType () const |
Return the result type of this rewrite. More... | |
bool | isExternal () const |
Returns true if this rewrite is external. More... | |
Static Public Member Functions | |
static UserRewriteDecl * | createNative (Context &ctx, const Name &name, ArrayRef< VariableDecl * > inputs, ArrayRef< VariableDecl * > results, std::optional< StringRef > codeBlock, Type resultType) |
Create a native rewrite with the given optional code block. More... | |
static UserRewriteDecl * | createPDLL (Context &ctx, const Name &name, ArrayRef< VariableDecl * > inputs, ArrayRef< VariableDecl * > results, const CompoundStmt *body, Type resultType) |
Create a PDLL rewrite with the given body. More... | |
Static Public Member Functions inherited from mlir::pdll::ast::Node::NodeBase< T, BaseT > | |
static bool | classof (const Node *node) |
Provide type casting support. More... | |
Additional Inherited Members | |
Public Types inherited from mlir::pdll::ast::Node::NodeBase< T, BaseT > | |
using | Base = NodeBase< T, BaseT > |
Protected Member Functions inherited from mlir::pdll::ast::Node::NodeBase< T, BaseT > | |
template<typename... Args> | |
NodeBase (SMRange loc, Args &&...args) | |
This decl represents a user defined rewrite.
This is either:
|
inlinestatic |
|
inlinestatic |
|
inline |
|
inline |
|
inline |
Return the input arguments of this rewrite.
Definition at line 1118 of file Nodes.h.
Referenced by getInputs().
|
inline |
Definition at line 1121 of file Nodes.h.
References getInputs().
|
inline |
Return the name of the rewrite.
Definition at line 1115 of file Nodes.h.
References mlir::pdll::ast::Decl::getName().
|
inline |
Return the explicit results of the rewrite declaration.
May be empty, even if the rewrite has results (e.g. in the case of inferred results).
Definition at line 1127 of file Nodes.h.
Referenced by getResults().
|
inline |
Definition at line 1130 of file Nodes.h.
References getResults().
|
inline |
|
inline |