MLIR  20.0.0git
Public Types | Public Member Functions | Public Attributes | List of all members
mlir::bufferization::func_ext::FuncAnalysisState Struct Reference

Extra analysis state that is required for bufferization of function boundaries. More...

#include "mlir/Dialect/Bufferization/Transforms/FuncBufferizableOpInterfaceImpl.h"

+ Inheritance diagram for mlir::bufferization::func_ext::FuncAnalysisState:

Public Types

using BbArgIndexSet = DenseSet< int64_t >
 A set of block argument indices. More...
 
using IndexMapping = DenseMap< int64_t, int64_t >
 A mapping of indices to indices. More...
 
using IndexToIndexListMapping = DenseMap< int64_t, SmallVector< int64_t > >
 A mapping of indices to a list of indices. More...
 

Public Member Functions

 FuncAnalysisState (OneShotAnalysisState &state)
 
void startFunctionAnalysis (FunctionOpInterface funcOp)
 This function is called right before analyzing the given FuncOp. More...
 
- Public Member Functions inherited from mlir::bufferization::OneShotAnalysisState::Extension
virtual ~Extension ()
 Base virtual destructor. More...
 

Public Attributes

DenseMap< FunctionOpInterface, IndexMappingequivalentFuncArgs
 A mapping of ReturnOp OpOperand indices to equivalent FuncOp BBArg indices. More...
 
DenseMap< FunctionOpInterface, IndexToIndexListMappingaliasingReturnVals
 A mapping of FuncOp BBArg indices to aliasing ReturnOp OpOperand indices. More...
 
DenseMap< FunctionOpInterface, BbArgIndexSetreadBbArgs
 A set of all read BlockArguments of FuncOps. More...
 
DenseMap< FunctionOpInterface, BbArgIndexSetwrittenBbArgs
 A set of all written-to BlockArguments of FuncOps. More...
 
DenseMap< FunctionOpInterface, FuncOpAnalysisStateanalyzedFuncOps
 Keep track of which FuncOps are fully analyzed or currently being analyzed. More...
 

Additional Inherited Members

- Protected Member Functions inherited from mlir::bufferization::OneShotAnalysisState::Extension
 Extension (OneShotAnalysisState &state)
 Constructs an extension of the given state object. More...
 
const OneShotAnalysisStategetAnalysisState () const
 Provides read-only access to the parent OneShotAnalysisState object. More...
 

Detailed Description

Extra analysis state that is required for bufferization of function boundaries.

Definition at line 32 of file FuncBufferizableOpInterfaceImpl.h.

Member Typedef Documentation

◆ BbArgIndexSet

A set of block argument indices.

Definition at line 43 of file FuncBufferizableOpInterfaceImpl.h.

◆ IndexMapping

A mapping of indices to indices.

Definition at line 46 of file FuncBufferizableOpInterfaceImpl.h.

◆ IndexToIndexListMapping

A mapping of indices to a list of indices.

Definition at line 49 of file FuncBufferizableOpInterfaceImpl.h.

Constructor & Destructor Documentation

◆ FuncAnalysisState()

mlir::bufferization::func_ext::FuncAnalysisState::FuncAnalysisState ( OneShotAnalysisState state)
inline

Definition at line 33 of file FuncBufferizableOpInterfaceImpl.h.

Member Function Documentation

◆ startFunctionAnalysis()

void mlir::bufferization::func_ext::FuncAnalysisState::startFunctionAnalysis ( FunctionOpInterface  funcOp)

This function is called right before analyzing the given FuncOp.

It initializes the data structures for the FuncOp in this state object.

Definition at line 25 of file FuncBufferizableOpInterfaceImpl.cpp.

References aliasingReturnVals, analyzedFuncOps, equivalentFuncArgs, mlir::bufferization::func_ext::InProgress, readBbArgs, and writtenBbArgs.

Member Data Documentation

◆ aliasingReturnVals

DenseMap<FunctionOpInterface, IndexToIndexListMapping> mlir::bufferization::func_ext::FuncAnalysisState::aliasingReturnVals

A mapping of FuncOp BBArg indices to aliasing ReturnOp OpOperand indices.

Definition at line 56 of file FuncBufferizableOpInterfaceImpl.h.

Referenced by startFunctionAnalysis().

◆ analyzedFuncOps

DenseMap<FunctionOpInterface, FuncOpAnalysisState> mlir::bufferization::func_ext::FuncAnalysisState::analyzedFuncOps

Keep track of which FuncOps are fully analyzed or currently being analyzed.

Definition at line 66 of file FuncBufferizableOpInterfaceImpl.h.

Referenced by startFunctionAnalysis().

◆ equivalentFuncArgs

DenseMap<FunctionOpInterface, IndexMapping> mlir::bufferization::func_ext::FuncAnalysisState::equivalentFuncArgs

A mapping of ReturnOp OpOperand indices to equivalent FuncOp BBArg indices.

Definition at line 53 of file FuncBufferizableOpInterfaceImpl.h.

Referenced by startFunctionAnalysis().

◆ readBbArgs

DenseMap<FunctionOpInterface, BbArgIndexSet> mlir::bufferization::func_ext::FuncAnalysisState::readBbArgs

A set of all read BlockArguments of FuncOps.

Definition at line 59 of file FuncBufferizableOpInterfaceImpl.h.

Referenced by startFunctionAnalysis().

◆ writtenBbArgs

DenseMap<FunctionOpInterface, BbArgIndexSet> mlir::bufferization::func_ext::FuncAnalysisState::writtenBbArgs

A set of all written-to BlockArguments of FuncOps.

Definition at line 62 of file FuncBufferizableOpInterfaceImpl.h.

Referenced by startFunctionAnalysis().


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