MLIR  22.0.0git
Public Attributes | List of all members
MlirRewritePatternCallbacks Struct Reference

RewritePattern API. More...

#include "mlir-c/Rewrite.h"

Public Attributes

void(* construct )(void *userData)
 Optional constructor for the user data. More...
 
void(* destruct )(void *userData)
 Optional destructor for the user data. More...
 
MlirLogicalResult(* matchAndRewrite )(MlirRewritePattern pattern, MlirOperation op, MlirPatternRewriter rewriter, void *userData)
 The callback function to match against code rooted at the specified operation, and perform the rewrite if the match is successful, corresponding to RewritePattern::matchAndRewrite. More...
 

Detailed Description

RewritePattern API.

Callbacks to construct a rewrite pattern.

Definition at line 337 of file Rewrite.h.

Member Data Documentation

◆ construct

void(* MlirRewritePatternCallbacks::construct) (void *userData)

Optional constructor for the user data.

Set to nullptr to disable it.

Definition at line 340 of file Rewrite.h.

Referenced by mlir::ExternalRewritePattern::ExternalRewritePattern().

◆ destruct

void(* MlirRewritePatternCallbacks::destruct) (void *userData)

Optional destructor for the user data.

Set to nullptr to disable it.

Definition at line 343 of file Rewrite.h.

Referenced by mlir::ExternalRewritePattern::~ExternalRewritePattern().

◆ matchAndRewrite

MlirLogicalResult(* MlirRewritePatternCallbacks::matchAndRewrite) (MlirRewritePattern pattern, MlirOperation op, MlirPatternRewriter rewriter, void *userData)

The callback function to match against code rooted at the specified operation, and perform the rewrite if the match is successful, corresponding to RewritePattern::matchAndRewrite.

Definition at line 347 of file Rewrite.h.

Referenced by mlir::ExternalRewritePattern::matchAndRewrite().


The documentation for this struct was generated from the following file: