MLIR  20.0.0git
Public Member Functions | List of all members
mlir::PredecessorIterator Class Referencefinal

Implement a predecessor iterator for blocks. More...

#include "mlir/IR/BlockSupport.h"

+ Inheritance diagram for mlir::PredecessorIterator:

Public Member Functions

 PredecessorIterator (ValueUseIterator< BlockOperand > it)
 Initializes the operand type iterator to the specified operand iterator. More...
 
 PredecessorIterator (BlockOperand *operand)
 
unsigned getSuccessorIndex () const
 Get the successor number in the predecessor terminator. More...
 

Detailed Description

Implement a predecessor iterator for blocks.

This works by walking the use lists of the blocks. The entries on this list are the BlockOperands that are embedded into terminator operations. From the operand, we can get the terminator that contains it, and its parent block is the predecessor.

Definition at line 49 of file BlockSupport.h.

Constructor & Destructor Documentation

◆ PredecessorIterator() [1/2]

mlir::PredecessorIterator::PredecessorIterator ( ValueUseIterator< BlockOperand it)
inline

Initializes the operand type iterator to the specified operand iterator.

Definition at line 56 of file BlockSupport.h.

References unwrap().

◆ PredecessorIterator() [2/2]

mlir::PredecessorIterator::PredecessorIterator ( BlockOperand operand)
inlineexplicit

Definition at line 59 of file BlockSupport.h.

Member Function Documentation

◆ getSuccessorIndex()

unsigned PredecessorIterator::getSuccessorIndex ( ) const

Get the successor number in the predecessor terminator.

Definition at line 332 of file Block.cpp.


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