|
CIRCT 22.0.0git
|
Base symbol cache class to allow for cache lookup through a pointer to some abstract cache. More...
#include <SymCache.h>

Classes | |
| struct | CacheIteratorImpl |
| struct | Iterator |
Public Types | |
| using | CacheItem = std::pair< mlir::Attribute, mlir::Operation * > |
| Iterator support through a pointer to some abstract cache. | |
Public Member Functions | |
| virtual | ~SymbolCacheBase () |
| Virtual method anchor. | |
| virtual void | addDefinition (mlir::Attribute symbol, mlir::Operation *op)=0 |
| Defines 'op' as associated with the 'symbol' in the cache. | |
| void | addSymbol (mlir::SymbolOpInterface op) |
| Adds the symbol-defining 'op' to the cache. | |
| void | addDefinitions (mlir::Operation *top) |
| Populate the symbol cache with all symbol-defining operations within the 'top' operation. | |
| virtual mlir::Operation * | getDefinition (mlir::Attribute symbol) const =0 |
| Lookup a definition for 'symbol' in the cache. | |
| mlir::Operation * | getDefinition (mlir::FlatSymbolRefAttr symbol) const |
| Lookup a definition for 'symbol' in the cache. | |
| virtual Iterator | begin ()=0 |
| virtual Iterator | end ()=0 |
Base symbol cache class to allow for cache lookup through a pointer to some abstract cache.
A symbol cache stores lookup tables to make manipulating and working with the IR more efficient.
Definition at line 25 of file SymCache.h.
| using circt::SymbolCacheBase::CacheItem = std::pair<mlir::Attribute, mlir::Operation *> |
Iterator support through a pointer to some abstract cache.
The implementing cache must provide an iterator that carries values on the form of <mlir::Attribute, mlir::Operation*>.
Definition at line 52 of file SymCache.h.
|
virtual |
Virtual method anchor.
Definition at line 21 of file SymCache.cpp.
|
pure virtual |
Defines 'op' as associated with the 'symbol' in the cache.
Implemented in circt::hw::HWSymbolCache, and circt::SymbolCache.
Referenced by addSymbol().
| void circt::SymbolCacheBase::addDefinitions | ( | mlir::Operation * | top | ) |
Populate the symbol cache with all symbol-defining operations within the 'top' operation.
Definition at line 23 of file SymCache.cpp.
References addSymbol().
Referenced by circt::SMTGlobalsHandler::create(), circt::FirMemLowering::FirMemLowering(), and circt::SMTGlobalsHandler::SMTGlobalsHandler().
|
inline |
Adds the symbol-defining 'op' to the cache.
Definition at line 33 of file SymCache.h.
References addDefinition().
Referenced by addDefinitions().
|
pure virtual |
Implemented in circt::hw::HWSymbolCache, and circt::SymbolCache.
|
pure virtual |
Implemented in circt::hw::HWSymbolCache, and circt::SymbolCache.
|
pure virtual |
Lookup a definition for 'symbol' in the cache.
Implemented in circt::hw::HWSymbolCache, circt::SymbolCache, circt::hw::HWSymbolCache, and circt::SymbolCache.
Referenced by getDefinition().
|
inline |
Lookup a definition for 'symbol' in the cache.
Definition at line 45 of file SymCache.h.
References getDefinition().