CIRCT 24.0.0git
Loading...
Searching...
No Matches
circt::fsm::FSMTransitionEdge Class Reference

This is an edge in the FSMGraph. More...

#include <FSMGraph.h>

Inheritance diagram for circt::fsm::FSMTransitionEdge:
Collaboration diagram for circt::fsm::FSMTransitionEdge:

Public Member Functions

FSMStateNode * getCurrentState () const
 Get the state where the transition originates from.
FSMStateNode * getNextState () const
 Get the module which the FSM-like is instantiating.
TransitionOp getTransition () const
void erase ()
 Erase this transition, removing it from the source state and the target state's use-list.

Private Member Functions

 FSMTransitionEdge (FSMStateNode *currentState, TransitionOp transition, FSMStateNode *nextState)
 FSMTransitionEdge (const FSMTransitionEdge &)=delete

Private Attributes

FSMStateNode * currentState
 The state where this transition originates from.
TransitionOp transition
 The transition that this is tracking.
FSMStateNode * nextState
 The next state of this transition.
FSMTransitionEdge * nextUse = nullptr
 Intrusive linked list for other uses.
FSMTransitionEdge * prevUse = nullptr

Friends

class FSMGraphBase
class FSMStateNode

Detailed Description

This is an edge in the FSMGraph.

This tracks a transition between two states.

Definition at line 91 of file FSMGraph.h.

Constructor & Destructor Documentation

◆ FSMTransitionEdge() [1/2]

circt::fsm::FSMTransitionEdge::FSMTransitionEdge ( FSMStateNode * currentState,
TransitionOp transition,
FSMStateNode * nextState )
inlineprivate

Definition at line 110 of file FSMGraph.h.

References currentState, FSMStateNode, nextState, and transition.

Referenced by FSMTransitionEdge().

◆ FSMTransitionEdge() [2/2]

circt::fsm::FSMTransitionEdge::FSMTransitionEdge ( const FSMTransitionEdge & )
privatedelete

References FSMTransitionEdge().

Member Function Documentation

◆ erase()

void FSMTransitionEdge::erase ( )

Erase this transition, removing it from the source state and the target state's use-list.

Definition at line 14 of file FSMGraph.cpp.

References currentState, erase(), nextState, nextUse, and prevUse.

Referenced by erase().

◆ getCurrentState()

FSMStateNode * circt::fsm::FSMTransitionEdge::getCurrentState ( ) const
inline

Get the state where the transition originates from.

Definition at line 95 of file FSMGraph.h.

References currentState, and FSMStateNode.

◆ getNextState()

FSMStateNode * circt::fsm::FSMTransitionEdge::getNextState ( ) const
inline

Get the module which the FSM-like is instantiating.

Definition at line 98 of file FSMGraph.h.

References FSMStateNode, and nextState.

Referenced by llvm::GraphTraits< circt::fsm::FSMStateNode * >::getNextState().

◆ getTransition()

TransitionOp circt::fsm::FSMTransitionEdge::getTransition ( ) const
inline

◆ FSMGraphBase

friend class FSMGraphBase
friend

Definition at line 107 of file FSMGraph.h.

References FSMGraphBase.

Referenced by FSMGraphBase.

◆ FSMStateNode

friend class FSMStateNode
friend

Definition at line 108 of file FSMGraph.h.

References FSMStateNode.

Referenced by FSMStateNode, FSMTransitionEdge(), getCurrentState(), and getNextState().

Member Data Documentation

◆ currentState

FSMStateNode* circt::fsm::FSMTransitionEdge::currentState
private

The state where this transition originates from.

Definition at line 117 of file FSMGraph.h.

Referenced by erase(), FSMTransitionEdge(), and getCurrentState().

◆ nextState

FSMStateNode* circt::fsm::FSMTransitionEdge::nextState
private

The next state of this transition.

Definition at line 123 of file FSMGraph.h.

Referenced by erase(), FSMTransitionEdge(), and getNextState().

◆ nextUse

FSMTransitionEdge* circt::fsm::FSMTransitionEdge::nextUse = nullptr
private

Intrusive linked list for other uses.

Definition at line 126 of file FSMGraph.h.

Referenced by erase(), and circt::fsm::FSMStateNode::recordUse().

◆ prevUse

FSMTransitionEdge* circt::fsm::FSMTransitionEdge::prevUse = nullptr
private

Definition at line 127 of file FSMGraph.h.

Referenced by erase().

◆ transition

TransitionOp circt::fsm::FSMTransitionEdge::transition
private

The transition that this is tracking.

Definition at line 120 of file FSMGraph.h.

Referenced by FSMTransitionEdge(), and getTransition().


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