|
CIRCT 22.0.0git
|
A wrapper class to uniformly handle def-use and auxiliary dependence edges. More...
#include <DependenceIterator.h>

Public Types | |
| using | TupleRepr = std::tuple< Operation *, Operation *, std::optional< unsigned >, std::optional< unsigned > > |
| The "expanded" representation of a dependence, intended as the key for comparisons and hashing. | |
Public Member Functions | |
| Dependence (OpOperand *defUseDep) | |
Wrap a def-use dependence, which is uniquely identified in the SSA graph by an OpOperand. | |
| Dependence (std::pair< Operation *, Operation * > auxDep) | |
| Wrap an auxiliary dependence, identified by the pair of its endpoints. | |
| Dependence (Operation *from, Operation *to) | |
Wrap an auxiliary dependence between from and to. | |
| Dependence () | |
| Construct an invalid dependence. | |
| bool | isAuxiliary () const |
| Return true if this is a valid auxiliary dependence. | |
| bool | isDefUse () const |
| Return true if this is a valid def-use dependence. | |
| bool | isInvalid () const |
| Return true if this is an invalid dependence. | |
| Operation * | getSource () const |
| Return the source of the dependence. | |
| Operation * | getDestination () const |
| Return the destination of the dependence. | |
| std::optional< unsigned > | getSourceIndex () const |
| Return the source operation's result number, if applicable. | |
| std::optional< unsigned > | getDestinationIndex () const |
| Return the destination operation's operand number, if applicable. | |
| TupleRepr | getAsTuple () const |
| Return the tuple representation of this dependence. | |
| bool | operator== (const Dependence &other) const |
Private Attributes | ||
| Operation * | auxSrc | |
| union { | ||
| Operation * auxDst | ||
| OpOperand * defUse | ||
| }; | ||
A wrapper class to uniformly handle def-use and auxiliary dependence edges.
Should be small enough (two pointers) to be passed around by value.
Definition at line 34 of file DependenceIterator.h.
| using circt::scheduling::detail::Dependence::TupleRepr = std::tuple<Operation *, Operation *, std::optional<unsigned>, std::optional<unsigned> > |
The "expanded" representation of a dependence, intended as the key for comparisons and hashing.
Definition at line 38 of file DependenceIterator.h.
|
inline |
Wrap a def-use dependence, which is uniquely identified in the SSA graph by an OpOperand.
Definition at line 44 of file DependenceIterator.h.
|
inline |
Wrap an auxiliary dependence, identified by the pair of its endpoints.
Definition at line 46 of file DependenceIterator.h.
|
inline |
Wrap an auxiliary dependence between from and to.
Definition at line 49 of file DependenceIterator.h.
|
inline |
Construct an invalid dependence.
Definition at line 51 of file DependenceIterator.h.
| Dependence::TupleRepr Dependence::getAsTuple | ( | ) | const |
Return the tuple representation of this dependence.
Definition at line 511 of file Problems.cpp.
Referenced by llvm::DenseMapInfo< Dependence >::getHashValue(), and operator==().
| Operation * Dependence::getDestination | ( | ) | const |
Return the destination of the dependence.
Definition at line 493 of file Problems.cpp.
Referenced by circt::scheduling::ChainingCyclicProblem::checkDefUse(), circt::scheduling::Problem::insertDependence(), circt::scheduling::Problem::verifyPrecedence(), circt::scheduling::CyclicProblem::verifyPrecedence(), and circt::scheduling::ChainingProblem::verifyPrecedenceInCycle().
| std::optional< unsigned > Dependence::getDestinationIndex | ( | ) | const |
Return the destination operation's operand number, if applicable.
Definition at line 505 of file Problems.cpp.
| Operation * Dependence::getSource | ( | ) | const |
Return the source of the dependence.
Definition at line 489 of file Problems.cpp.
Referenced by circt::scheduling::detail::DependenceIterator::findNextDependence(), circt::scheduling::Problem::insertDependence(), circt::scheduling::Problem::verifyPrecedence(), circt::scheduling::CyclicProblem::verifyPrecedence(), and circt::scheduling::ChainingProblem::verifyPrecedenceInCycle().
| std::optional< unsigned > Dependence::getSourceIndex | ( | ) | const |
Return the source operation's result number, if applicable.
Definition at line 497 of file Problems.cpp.
References assert().
|
inline |
Return true if this is a valid auxiliary dependence.
Definition at line 54 of file DependenceIterator.h.
References auxDst, and auxSrc.
Referenced by circt::scheduling::ChainingCyclicProblem::checkDefUse(), circt::scheduling::Problem::insertDependence(), and circt::scheduling::ChainingProblem::verifyPrecedenceInCycle().
|
inline |
Return true if this is a valid def-use dependence.
Definition at line 56 of file DependenceIterator.h.
|
inline |
Return true if this is an invalid dependence.
Definition at line 58 of file DependenceIterator.h.
References auxDst.
| bool Dependence::operator== | ( | const Dependence & | other | ) | const |
Definition at line 516 of file Problems.cpp.
References getAsTuple().
| union { ... } circt::scheduling::detail::Dependence |
| Operation* circt::scheduling::detail::Dependence::auxDst |
Definition at line 78 of file DependenceIterator.h.
Referenced by isAuxiliary(), isDefUse(), and isInvalid().
|
private |
Definition at line 76 of file DependenceIterator.h.
Referenced by isAuxiliary(), and isDefUse().
| OpOperand* circt::scheduling::detail::Dependence::defUse |
Definition at line 79 of file DependenceIterator.h.