CIRCT 22.0.0git
|
Simple technology library encoded as a HWModuleOp. More...
Public Member Functions | |
TechLibraryPattern (hw::HWModuleOp module, double area, SmallVector< SmallVector< DelayType, 2 >, 4 > delay, NPNClass npnClass) | |
StringRef | getPatternName () const override |
Get the name of this pattern. Used for debugging. | |
bool | match (const Cut &cut) const override |
Match the cut set against this library primitive. | |
bool | useTruthTableMatcher (SmallVectorImpl< NPNClass > &matchingNPNClasses) const override |
Enable truth table matching for this pattern. | |
llvm::FailureOr< Operation * > | rewrite (mlir::OpBuilder &builder, Cut &cut) const override |
Rewrite the cut set using this library primitive. | |
double | getArea () const override |
Get the area cost of this pattern. | |
DelayType | getDelay (unsigned inputIndex, unsigned outputIndex) const override |
Get the delay between specific input and output. | |
unsigned | getNumInputs () const |
unsigned | getNumOutputs () const override |
Get the number of outputs this pattern produces. | |
LocationAttr | getLoc () const override |
Get location for this pattern(optional). | |
![]() | |
CutRewritePattern (mlir::MLIRContext *context) | |
virtual | ~CutRewritePattern ()=default |
Virtual destructor for base class. | |
mlir::MLIRContext * | getContext () const |
Private Attributes | |
const double | area |
const SmallVector< SmallVector< DelayType, 2 >, 4 > | delay |
hw::HWModuleOp NPNClass | npnClass |
Simple technology library encoded as a HWModuleOp.
Definition at line 88 of file TechMapper.cpp.
|
inline |
Definition at line 89 of file TechMapper.cpp.
|
inlineoverridevirtual |
Get the area cost of this pattern.
Implements circt::synth::CutRewritePattern.
Definition at line 135 of file TechMapper.cpp.
References area.
|
inlineoverridevirtual |
Get the delay between specific input and output.
NOTE: The input index is already permuted according to the pattern's input permutation, so it's not necessary to account for it here.
Implements circt::synth::CutRewritePattern.
Definition at line 137 of file TechMapper.cpp.
References delay.
|
inlineoverridevirtual |
Get location for this pattern(optional).
Reimplemented from circt::synth::CutRewritePattern.
Definition at line 149 of file TechMapper.cpp.
|
inline |
Definition at line 141 of file TechMapper.cpp.
|
inlineoverridevirtual |
Get the number of outputs this pattern produces.
Implements circt::synth::CutRewritePattern.
Definition at line 145 of file TechMapper.cpp.
|
inlineoverridevirtual |
Get the name of this pattern. Used for debugging.
Reimplemented from circt::synth::CutRewritePattern.
Definition at line 105 of file TechMapper.cpp.
|
inlineoverridevirtual |
Match the cut set against this library primitive.
Implements circt::synth::CutRewritePattern.
Definition at line 111 of file TechMapper.cpp.
References circt::NPNClass::equivalentOtherThanPermutation(), circt::synth::Cut::getNPNClass(), and npnClass.
|
inlineoverridevirtual |
Rewrite the cut set using this library primitive.
Implements circt::synth::CutRewritePattern.
Definition at line 123 of file TechMapper.cpp.
References circt::synth::Cut::getPermutatedInputs(), circt::synth::Cut::getRoot(), and npnClass.
|
inlineoverridevirtual |
Enable truth table matching for this pattern.
Reimplemented from circt::synth::CutRewritePattern.
Definition at line 116 of file TechMapper.cpp.
References npnClass.
|
private |
Definition at line 155 of file TechMapper.cpp.
Referenced by getArea().
|
private |
Definition at line 156 of file TechMapper.cpp.
Referenced by getDelay(), and synth.DataflowPath::to_flamegraph().
|
private |
Definition at line 158 of file TechMapper.cpp.
Referenced by match(), rewrite(), and useTruthTableMatcher().