MLIR  20.0.0git
Public Member Functions | List of all members
mlir::dataflow::Executable Class Reference

This is a simple analysis state that represents whether the associated lattice anchor (either a block or a control-flow edge) is live. More...

#include "mlir/Analysis/DataFlow/DeadCodeAnalysis.h"

+ Inheritance diagram for mlir::dataflow::Executable:

Public Member Functions

ChangeResult setToLive ()
 Set the state of the lattice anchor to live. More...
 
bool isLive () const
 Get whether the lattice anchor is live. More...
 
void print (raw_ostream &os) const override
 Print the liveness. More...
 
void onUpdate (DataFlowSolver *solver) const override
 When the state of the lattice anchor is changed to live, re-invoke subscribed analyses on the operations in the block and on the block itself. More...
 
void blockContentSubscribe (DataFlowAnalysis *analysis)
 Subscribe an analysis to changes to the liveness. More...
 
 AnalysisState (LatticeAnchor anchor)
 Create the analysis state on the given lattice anchor. More...
 
- Public Member Functions inherited from mlir::AnalysisState
virtual ~AnalysisState ()
 
 AnalysisState (LatticeAnchor anchor)
 Create the analysis state on the given lattice anchor. More...
 
LatticeAnchor getAnchor () const
 Returns the lattice anchor this state is located at. More...
 
LLVM_DUMP_METHOD void dump () const
 
void addDependency (ProgramPoint *point, DataFlowAnalysis *analysis)
 Add a dependency to this analysis state on a lattice anchor and an analysis. More...
 

Additional Inherited Members

- Protected Attributes inherited from mlir::AnalysisState
LatticeAnchor anchor
 The lattice anchor to which the state belongs. More...
 

Detailed Description

This is a simple analysis state that represents whether the associated lattice anchor (either a block or a control-flow edge) is live.

Definition at line 39 of file DeadCodeAnalysis.h.

Member Function Documentation

◆ AnalysisState()

mlir::AnalysisState::AnalysisState
inline

Create the analysis state on the given lattice anchor.

Definition at line 459 of file DataFlowFramework.h.

◆ blockContentSubscribe()

void mlir::dataflow::Executable::blockContentSubscribe ( DataFlowAnalysis analysis)
inline

Subscribe an analysis to changes to the liveness.

Definition at line 58 of file DeadCodeAnalysis.h.

◆ isLive()

bool mlir::dataflow::Executable::isLive ( ) const
inline

Get whether the lattice anchor is live.

Definition at line 47 of file DeadCodeAnalysis.h.

◆ onUpdate()

void Executable::onUpdate ( DataFlowSolver solver) const
overridevirtual

When the state of the lattice anchor is changed to live, re-invoke subscribed analyses on the operations in the block and on the block itself.

Reimplemented from mlir::AnalysisState.

Definition at line 46 of file DeadCodeAnalysis.cpp.

References mlir::AnalysisState::anchor, mlir::DataFlowSolver::enqueue(), mlir::Operation::getBlock(), mlir::DataFlowSolver::getProgramPointAfter(), mlir::DataFlowSolver::getProgramPointBefore(), and mlir::AnalysisState::onUpdate().

◆ print()

void Executable::print ( raw_ostream &  os) const
overridevirtual

Print the liveness.

Implements mlir::AnalysisState.

Definition at line 42 of file DeadCodeAnalysis.cpp.

◆ setToLive()

ChangeResult Executable::setToLive ( )

Set the state of the lattice anchor to live.

Definition at line 35 of file DeadCodeAnalysis.cpp.

References mlir::Change, and mlir::NoChange.


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