CIRCT  20.0.0git
Public Member Functions | List of all members
circt::firrtl::CircuitNamespace Struct Reference

The namespace of a CircuitOp, generally inhabited by modules. More...

#include <Namespace.h>

Inheritance diagram for circt::firrtl::CircuitNamespace:
Inheritance graph
[legend]
Collaboration diagram for circt::firrtl::CircuitNamespace:
Collaboration graph
[legend]

Public Member Functions

 CircuitNamespace ()
 
 CircuitNamespace (CircuitOp circuit)
 
void add (CircuitOp circuit)
 Populate the namespace from a circuit operation. More...
 
- Public Member Functions inherited from circt::Namespace
 Namespace ()
 
 Namespace (const Namespace &other)=default
 
 Namespace (Namespace &&other)
 
Namespaceoperator= (const Namespace &other)=default
 
Namespaceoperator= (Namespace &&other)
 
void add (mlir::ModuleOp module)
 
void add (SymbolCache &symCache)
 SymbolCache initializer; initialize from every key that is convertible to a StringAttr in the SymbolCache. More...
 
bool erase (llvm::StringRef symbol)
 Removes a symbol from the namespace. More...
 
void clear ()
 Empty the namespace. More...
 
StringRef newName (const Twine &name)
 Return a unique name, derived from the input name, and add the new name to the internal namespace. More...
 
StringRef newName (const Twine &name, const Twine &suffix)
 Return a unique name, derived from the input name and ensure the returned name has the input suffix. More...
 

Additional Inherited Members

- Protected Attributes inherited from circt::Namespace
llvm::StringMap< size_t > nextIndex
 
bool locked = false
 

Detailed Description

The namespace of a CircuitOp, generally inhabited by modules.

Definition at line 24 of file Namespace.h.

Constructor & Destructor Documentation

◆ CircuitNamespace() [1/2]

circt::firrtl::CircuitNamespace::CircuitNamespace ( )
inline

Definition at line 25 of file Namespace.h.

◆ CircuitNamespace() [2/2]

circt::firrtl::CircuitNamespace::CircuitNamespace ( CircuitOp  circuit)
inline

Definition at line 26 of file Namespace.h.

References add().

Member Function Documentation

◆ add()

void circt::firrtl::CircuitNamespace::add ( CircuitOp  circuit)
inline

Populate the namespace from a circuit operation.

This namespace will be composed of any operation in the first level of the circuit that contains a symbol.

Definition at line 31 of file Namespace.h.

References circt::Namespace::nextIndex.

Referenced by CircuitNamespace().


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