ONE - On-device Neural Engine
Loading...
Searching...
No Matches
luci::CircleWhile Class Referencefinal

WHILE in Circle. More...

#include <CircleWhile.h>

Collaboration diagram for luci::CircleWhile:

Public Member Functions

 CircleWhile (uint32_t arity, uint32_t out)
 
uint32_t input_count (void) const
 
uint32_t output_count (void) const
 
Nodeinput (uint32_t index) const
 
void input (uint32_t index, Node *node)
 
int32_t cond_branch (void) const
 
void cond_branch (int32_t cond_branch)
 
int32_t body_branch (void) const
 
void body_branch (int32_t body_branch)
 
loco::Graphcond_graph (void) const
 
void cond_graph (loco::Graph *cond_graph)
 
loco::Graphbody_graph (void) const
 
void body_graph (loco::Graph *body_graph)
 
- Public Member Functions inherited from luci::VariadicArityNode< CircleNodeImpl< CircleOpcode::WHILE > >
 VariadicArityNode (uint32_t arity)
 
virtual ~VariadicArityNode ()=default
 
uint32_t arity (void) const final
 
loco::Nodearg (uint32_t n) const final
 
void drop (void) final
 
- Public Member Functions inherited from luci::CircleNodeImpl< CircleOpcode::WHILE >
virtual ~CircleNodeImpl ()=default
 
uint32_t opnum (void) const final
 
CircleOpcode opcode (void) const final
 
- Public Member Functions inherited from luci::CircleNode
virtual ~CircleNode ()=default
 
const loco::Dialectdialect (void) const final
 Return "Dialect" identifier that this node belongs to.
 
template<typename T >
accept (CircleNodeVisitorBase< T > *) const
 
template<typename T >
accept (CircleNodeMutableVisitorBase< T > *)
 
NodeName name (void) const
 
void name (const NodeName &name)
 
CircleQuantParamquantparam (void) const
 
void quantparam (std::unique_ptr< CircleQuantParam > &&quantparam)
 
SparsityParamsparsityparam (void) const
 
void sparsityparam (std::unique_ptr< SparsityParam > &&sparsityparam)
 
ShapeStatus shape_status (void) const
 
void shape_status (ShapeStatus ss)
 
int32_t op_version (void) const
 
void op_version (int32_t op_version)
 
- Public Member Functions inherited from loco::Node
 Node ()=default
 
 Node (const Node &)=delete
 
 Node (Node &&)=delete
 
virtual ~Node ()
 
Graphgraph (void)
 
const Graphgraph (void) const
 
- Public Member Functions inherited from loco::AnnotatedItem< NodeAnnotation >
 AnnotatedItem ()=default
 
virtual ~AnnotatedItem ()=default
 
const T * annot (void) const
 Retrieve a stored annotation of type T.
 
void annot (std::unique_ptr< T > &&p)
 Attach or remove a new annotation of type T.
 

Additional Inherited Members

- Protected Member Functions inherited from luci::VariadicArityNode< CircleNodeImpl< CircleOpcode::WHILE > >
loco::Useat (uint32_t n) const
 

Detailed Description

WHILE in Circle.

Definition at line 33 of file CircleWhile.h.

Constructor & Destructor Documentation

◆ CircleWhile()

luci::CircleWhile::CircleWhile ( uint32_t  arity,
uint32_t  out 
)
inline

Definition at line 36 of file CircleWhile.h.

37 : VariadicArityNode<CircleNodeImpl<CircleOpcode::WHILE>>(arity), _output_count(out)
38 {
39 assert(arity > 0);
40 assert(out > 0);
41
42 // input and output must have the same size
43 assert(arity == out);
44 }
uint32_t arity(void) const final
Return the number of arguments.

References luci::VariadicArityNode< CircleNodeImpl< CircleOpcode::WHILE > >::arity().

Member Function Documentation

◆ body_branch() [1/2]

void luci::CircleWhile::body_branch ( int32_t  body_branch)
inline

Definition at line 59 of file CircleWhile.h.

59{ _body_branch = body_branch; }
int32_t body_branch(void) const
Definition CircleWhile.h:58

References body_branch().

Referenced by body_branch().

◆ body_branch() [2/2]

int32_t luci::CircleWhile::body_branch ( void  ) const
inline

Definition at line 58 of file CircleWhile.h.

58{ return _body_branch; }

Referenced by luci::CircleWhileGraphBuilder::build(), and luci::BuiltinOptionsExtractor::visit().

◆ body_graph() [1/2]

void luci::CircleWhile::body_graph ( loco::Graph body_graph)
inline

Definition at line 66 of file CircleWhile.h.

66{ _body_graph = body_graph; }
loco::Graph * body_graph(void) const
Definition CircleWhile.h:65

References body_graph().

Referenced by body_graph().

◆ body_graph() [2/2]

loco::Graph * luci::CircleWhile::body_graph ( void  ) const
inline

Definition at line 65 of file CircleWhile.h.

65{ return _body_graph; }

◆ cond_branch() [1/2]

void luci::CircleWhile::cond_branch ( int32_t  cond_branch)
inline

Definition at line 56 of file CircleWhile.h.

56{ _cond_branch = cond_branch; }
int32_t cond_branch(void) const
Definition CircleWhile.h:55

References cond_branch().

Referenced by cond_branch().

◆ cond_branch() [2/2]

int32_t luci::CircleWhile::cond_branch ( void  ) const
inline

Definition at line 55 of file CircleWhile.h.

55{ return _cond_branch; }

Referenced by luci::CircleWhileGraphBuilder::build(), and luci::BuiltinOptionsExtractor::visit().

◆ cond_graph() [1/2]

void luci::CircleWhile::cond_graph ( loco::Graph cond_graph)
inline

Definition at line 63 of file CircleWhile.h.

63{ _cond_graph = cond_graph; }
loco::Graph * cond_graph(void) const
Definition CircleWhile.h:62

References cond_graph().

Referenced by cond_graph().

◆ cond_graph() [2/2]

loco::Graph * luci::CircleWhile::cond_graph ( void  ) const
inline

Definition at line 62 of file CircleWhile.h.

62{ return _cond_graph; }

◆ input() [1/2]

Node * luci::CircleWhile::input ( uint32_t  index) const
inline

◆ input() [2/2]

void luci::CircleWhile::input ( uint32_t  index,
Node node 
)
inline

Definition at line 52 of file CircleWhile.h.

52{ at(index)->node(node); }

References luci::VariadicArityNode< CircleNodeImpl< CircleOpcode::WHILE > >::at(), and loco::Use::node().

◆ input_count()

uint32_t luci::CircleWhile::input_count ( void  ) const
inline

◆ output_count()

uint32_t luci::CircleWhile::output_count ( void  ) const
inline

Definition at line 48 of file CircleWhile.h.

48{ return _output_count; }

Referenced by luci::CloneNodeLet< CN::WXYZ >::visit().


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