MLIR 23.0.0git
mlir::RegionSuccessor Class Reference

This class represents a successor of a region. More...

#include "mlir/Interfaces/ControlFlowInterfaces.h"

Public Member Functions

 RegionSuccessor (Region *region)
 Initialize a successor that branches to a region of the parent operation.
 RegionSuccessor (Operation *operation)
 Initialize a successor that branches after/out of an operation.
RegiongetSuccessor () const
 Return the given region successor.
OperationgetSuccessorOp () const
 Return the given operation successor.
bool isRegion () const
 Return true if the successor is a region.
bool isOperation () const
 Return true if the successor is an operation.
bool operator== (RegionSuccessor rhs) const
bool operator== (const Region *region) const
bool operator== (const Operation *operation) const

Friends

bool operator!= (RegionSuccessor lhs, RegionSuccessor rhs)

Detailed Description

This class represents a successor of a region.

A region successor can either target another region or target an ancestor operation (at the moment, limited to the immediate parent operation). In the latter case, the control flow branches after/out of the target operation.

Definition at line 199 of file ControlFlowInterfaces.h.

Constructor & Destructor Documentation

◆ RegionSuccessor() [1/2]

mlir::RegionSuccessor::RegionSuccessor ( Region * region)
inline

Initialize a successor that branches to a region of the parent operation.

Definition at line 202 of file ControlFlowInterfaces.h.

Referenced by operator!=, and operator==().

◆ RegionSuccessor() [2/2]

mlir::RegionSuccessor::RegionSuccessor ( Operation * operation)
inline

Initialize a successor that branches after/out of an operation.

Definition at line 207 of file ControlFlowInterfaces.h.

Member Function Documentation

◆ getSuccessor()

Region * mlir::RegionSuccessor::getSuccessor ( ) const
inline

Return the given region successor.

Returns nullptr if the successor is an operation.

Definition at line 213 of file ControlFlowInterfaces.h.

Referenced by mlir::operator<<(), operator==(), mlir::dataflow::IntegerRangeAnalysis::visitNonControlFlowArguments(), and mlir::dataflow::LivenessAnalysis::visitNonControlFlowArguments().

◆ getSuccessorOp()

Operation * mlir::RegionSuccessor::getSuccessorOp ( ) const
inline

Return the given operation successor.

Returns nullptr if the successor is a region.

Definition at line 219 of file ControlFlowInterfaces.h.

Referenced by mlir::operator<<(), and operator==().

◆ isOperation()

bool mlir::RegionSuccessor::isOperation ( ) const
inline

Return true if the successor is an operation.

Definition at line 227 of file ControlFlowInterfaces.h.

Referenced by getSingleRegionSuccessorInputs().

◆ isRegion()

bool mlir::RegionSuccessor::isRegion ( ) const
inline

Return true if the successor is a region.

Definition at line 224 of file ControlFlowInterfaces.h.

Referenced by mlir::dataflow::LivenessAnalysis::visitNonControlFlowArguments().

◆ operator==() [1/3]

bool mlir::RegionSuccessor::operator== ( const Operation * operation) const
inline

Definition at line 237 of file ControlFlowInterfaces.h.

References getSuccessorOp().

◆ operator==() [2/3]

bool mlir::RegionSuccessor::operator== ( const Region * region) const
inline

Definition at line 233 of file ControlFlowInterfaces.h.

References getSuccessor().

◆ operator==() [3/3]

bool mlir::RegionSuccessor::operator== ( RegionSuccessor rhs) const
inline

Definition at line 229 of file ControlFlowInterfaces.h.

References RegionSuccessor(), and rhs.

◆ operator!=

bool operator!= ( RegionSuccessor lhs,
RegionSuccessor rhs )
friend

Definition at line 241 of file ControlFlowInterfaces.h.

References lhs, RegionSuccessor(), and rhs.


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