MLIR  20.0.0git
Classes | Public Member Functions | List of all members
mlir::PassInstrumentation Class Referenceabstract

PassInstrumentation provides several entry points into the pass manager infrastructure. More...

#include "mlir/Pass/PassInstrumentation.h"

Classes

struct  PipelineParentInfo
 This struct represents information related to the parent pass of pipeline. More...
 

Public Member Functions

virtual ~PassInstrumentation ()=0
 
virtual void runBeforePipeline (std::optional< OperationName > name, const PipelineParentInfo &parentInfo)
 A callback to run before a pass pipeline is executed. More...
 
virtual void runAfterPipeline (std::optional< OperationName > name, const PipelineParentInfo &parentInfo)
 A callback to run after a pass pipeline has executed. More...
 
virtual void runBeforePass (Pass *pass, Operation *op)
 A callback to run before a pass is executed. More...
 
virtual void runAfterPass (Pass *pass, Operation *op)
 A callback to run after a pass is successfully executed. More...
 
virtual void runAfterPassFailed (Pass *pass, Operation *op)
 A callback to run when a pass execution fails. More...
 
virtual void runBeforeAnalysis (StringRef name, TypeID id, Operation *op)
 A callback to run before an analysis is computed. More...
 
virtual void runAfterAnalysis (StringRef name, TypeID id, Operation *op)
 A callback to run before an analysis is computed. More...
 

Detailed Description

PassInstrumentation provides several entry points into the pass manager infrastructure.

Instrumentations should be added directly to a PassManager before running a pipeline.

Definition at line 28 of file PassInstrumentation.h.

Constructor & Destructor Documentation

◆ ~PassInstrumentation()

PassInstrumentation::~PassInstrumentation ( )
pure virtualdefault

Member Function Documentation

◆ runAfterAnalysis()

virtual void mlir::PassInstrumentation::runAfterAnalysis ( StringRef  name,
TypeID  id,
Operation op 
)
inlinevirtual

A callback to run before an analysis is computed.

This function takes the name of the analysis that was computed, its TypeID, as well as the current operation being analyzed.

Definition at line 82 of file PassInstrumentation.h.

◆ runAfterPass()

virtual void mlir::PassInstrumentation::runAfterPass ( Pass pass,
Operation op 
)
inlinevirtual

A callback to run after a pass is successfully executed.

This function takes a pointer to the pass to be executed, as well as the current operation being operated on.

Definition at line 66 of file PassInstrumentation.h.

◆ runAfterPassFailed()

virtual void mlir::PassInstrumentation::runAfterPassFailed ( Pass pass,
Operation op 
)
inlinevirtual

A callback to run when a pass execution fails.

This function takes a pointer to the pass that was being executed, as well as the current operation being operated on. Note that the operation may be in an invalid state.

Definition at line 72 of file PassInstrumentation.h.

◆ runAfterPipeline()

void PassInstrumentation::runAfterPipeline ( std::optional< OperationName name,
const PipelineParentInfo parentInfo 
)
virtual

A callback to run after a pass pipeline has executed.

This function takes the name of the operation type being operated on, or std::nullopt if the pipeline is op-agnostic, and information related to the parent that spawned this pipeline.

Definition at line 986 of file Pass.cpp.

◆ runBeforeAnalysis()

virtual void mlir::PassInstrumentation::runBeforeAnalysis ( StringRef  name,
TypeID  id,
Operation op 
)
inlinevirtual

A callback to run before an analysis is computed.

This function takes the name of the analysis to be computed, its TypeID, as well as the current operation being analyzed.

Definition at line 77 of file PassInstrumentation.h.

◆ runBeforePass()

virtual void mlir::PassInstrumentation::runBeforePass ( Pass pass,
Operation op 
)
inlinevirtual

A callback to run before a pass is executed.

This function takes a pointer to the pass to be executed, as well as the current operation being operated on.

Definition at line 61 of file PassInstrumentation.h.

◆ runBeforePipeline()

void PassInstrumentation::runBeforePipeline ( std::optional< OperationName name,
const PipelineParentInfo parentInfo 
)
virtual

A callback to run before a pass pipeline is executed.

This function takes the name of the operation type being operated on, or std::nullopt if the pipeline is op-agnostic, and information related to the parent that spawned this pipeline.

Definition at line 983 of file Pass.cpp.


The documentation for this class was generated from the following files: