CIRCT
20.0.0git
|
Instantiate for all Tcl emissions. More...
#include <ExportTcl.h>
Public Member Functions | |
TclEmitter (mlir::ModuleOp topLevel) | |
LogicalResult | emit (Operation *hwMod, StringRef outputFile) |
Write out all the relevant tcl commands. More... | |
Operation * | getDefinition (FlatSymbolRefAttr) |
const DenseSet< hw::HierPathOp > & | getRefsUsed () |
void | usedRef (hw::HierPathOp ref) |
Private Member Functions | |
LogicalResult | populate () |
Private Attributes | |
mlir::ModuleOp | topLevel |
bool | populated |
hw::HWSymbolCache | topLevelSymbols |
DenseMap< Operation *, llvm::MapVector< StringAttr, SmallVector< DynInstDataOpInterface, 0 > > > | tclOpsForModInstance |
Map Module operations to their top-level "instance" names. More... | |
DenseSet< hw::HierPathOp > | refsUsed |
Instantiate for all Tcl emissions.
We want to cache the symbols and binned ops – this helper class provides that caching.
Definition at line 29 of file ExportTcl.h.
TclEmitter::TclEmitter | ( | mlir::ModuleOp | topLevel | ) |
Definition at line 35 of file ExportQuartusTcl.cpp.
LogicalResult TclEmitter::emit | ( | Operation * | hwMod, |
StringRef | outputFile | ||
) |
Write out all the relevant tcl commands.
Create one 'proc' per module which takes the parent entity name since we don't assume that the created module is the top level for the entire design.
Definition at line 294 of file ExportQuartusTcl.cpp.
References circt::calyx::direction::get(), populate(), and tclOpsForModInstance.
Operation * TclEmitter::getDefinition | ( | FlatSymbolRefAttr | sym | ) |
Definition at line 74 of file ExportQuartusTcl.cpp.
References circt::hw::HWSymbolCache::getDefinition(), populate(), and topLevelSymbols.
|
inline |
Definition at line 35 of file ExportTcl.h.
References refsUsed.
|
private |
Definition at line 38 of file ExportQuartusTcl.cpp.
References circt::hw::HWSymbolCache::addDefinition(), assert(), circt::hw::HWSymbolCache::freeze(), circt::hw::HWSymbolCache::getDefinition(), populated, tclOpsForModInstance, topLevel, and topLevelSymbols.
Referenced by emit(), and getDefinition().
|
inline |
Definition at line 36 of file ExportTcl.h.
References refsUsed.
|
private |
Definition at line 41 of file ExportTcl.h.
Referenced by populate().
|
private |
Definition at line 49 of file ExportTcl.h.
Referenced by getRefsUsed(), and usedRef().
|
private |
Map Module operations to their top-level "instance" names.
Map those "instance" names to the lowered ops which get directly emitted as tcl.
Definition at line 48 of file ExportTcl.h.
Referenced by emit(), and populate().
|
private |
Definition at line 39 of file ExportTcl.h.
Referenced by populate().
|
private |
Definition at line 42 of file ExportTcl.h.
Referenced by getDefinition(), and populate().