CIRCT
20.0.0git
|
#include <CFToHandshake.h>
Classes | |
struct | MergeOpInfo |
Public Types | |
using | BlockValues = DenseMap< Block *, std::vector< Value > > |
using | BlockOps = DenseMap< Block *, std::vector< MergeOpInfo > > |
using | ValueMap = DenseMap< Value, Value > |
using | MemRefToMemoryAccessOp = llvm::MapVector< Value, std::vector< Operation * > > |
Public Member Functions | |
HandshakeLowering (Region &r) | |
LogicalResult | addMergeOps (ConversionPatternRewriter &rewriter) |
LogicalResult | addBranchOps (ConversionPatternRewriter &rewriter) |
LogicalResult | replaceCallOps (ConversionPatternRewriter &rewriter) |
template<typename TSrcTerm , typename TDstTerm > | |
LogicalResult | setControlOnlyPath (ConversionPatternRewriter &rewriter, Value entryCtrl) |
LogicalResult | connectConstantsToControl (ConversionPatternRewriter &rewriter, bool sourceConstants) |
LogicalResult | feedForwardRewriting (ConversionPatternRewriter &rewriter) |
LogicalResult | loopNetworkRewriting (ConversionPatternRewriter &rewriter) |
BlockOps | insertMergeOps (ValueMap &mergePairs, BackedgeBuilder &edgeBuilder, ConversionPatternRewriter &rewriter) |
MergeOpInfo | insertMerge (Block *block, Value val, BackedgeBuilder &edgeBuilder, ConversionPatternRewriter &rewriter) |
LogicalResult | replaceMemoryOps (ConversionPatternRewriter &rewriter, MemRefToMemoryAccessOp &memRefOps) |
LogicalResult | connectToMemory (ConversionPatternRewriter &rewriter, MemRefToMemoryAccessOp memRefOps, bool lsq) |
void | setMemOpControlInputs (ConversionPatternRewriter &rewriter, ArrayRef< Operation * > memOps, Operation *memOp, int offset, ArrayRef< int > cntrlInd) |
Value | getBlockEntryControl (Block *block) const |
void | setBlockEntryControl (Block *block, Value v) |
Region & | getRegion () |
MLIRContext * | getContext () |
Protected Member Functions | |
LogicalResult | runSSAMaximization (ConversionPatternRewriter &rewriter, Value entryCtrl) |
Protected Attributes | |
Region & | r |
BlockArgument | startCtrl |
Start point of the control-only network. More... | |
Private Attributes | |
DenseMap< Block *, Value > | blockEntryControlMap |
Definition at line 55 of file CFToHandshake.h.
using circt::handshake::HandshakeLowering::BlockOps = DenseMap<Block *, std::vector<MergeOpInfo> > |
Definition at line 65 of file CFToHandshake.h.
using circt::handshake::HandshakeLowering::BlockValues = DenseMap<Block *, std::vector<Value> > |
Definition at line 64 of file CFToHandshake.h.
using circt::handshake::HandshakeLowering::MemRefToMemoryAccessOp = llvm::MapVector<Value, std::vector<Operation *> > |
Definition at line 67 of file CFToHandshake.h.
using circt::handshake::HandshakeLowering::ValueMap = DenseMap<Value, Value> |
Definition at line 66 of file CFToHandshake.h.
|
inlineexplicit |
Definition at line 70 of file CFToHandshake.h.
LogicalResult HandshakeLowering::addBranchOps | ( | ConversionPatternRewriter & | rewriter | ) |
Definition at line 1127 of file CFToHandshake.cpp.
References getBranchCount(), getSuccResult(), and isLiveOut().
Referenced by circt::handshake::lowerRegion().
LogicalResult HandshakeLowering::addMergeOps | ( | ConversionPatternRewriter & | rewriter | ) |
Definition at line 498 of file CFToHandshake.cpp.
References reconnectMergeOps().
Referenced by circt::handshake::lowerRegion().
LogicalResult HandshakeLowering::connectConstantsToControl | ( | ConversionPatternRewriter & | rewriter, |
bool | sourceConstants | ||
) |
Definition at line 1178 of file CFToHandshake.cpp.
Referenced by circt::handshake::lowerRegion().
LogicalResult HandshakeLowering::connectToMemory | ( | ConversionPatternRewriter & | rewriter, |
MemRefToMemoryAccessOp | memRefOps, | ||
bool | lsq | ||
) |
Definition at line 1513 of file CFToHandshake.cpp.
References addJoinOps(), addLazyForks(), getControlTerminators(), getResultsToMemory(), isValidMemrefType(), removeUnusedAllocOps(), setJoinControlInputs(), and setLoadDataInputs().
Referenced by circt::handshake::lowerRegion().
LogicalResult HandshakeLowering::feedForwardRewriting | ( | ConversionPatternRewriter & | rewriter | ) |
Definition at line 586 of file CFToHandshake.cpp.
Referenced by circt::handshake::lowerRegion().
Value HandshakeLowering::getBlockEntryControl | ( | Block * | block | ) | const |
Definition at line 214 of file CFToHandshake.cpp.
References assert().
|
inline |
Definition at line 149 of file CFToHandshake.h.
References r.
|
inline |
Definition at line 148 of file CFToHandshake.h.
References r.
Referenced by circt::handshake::lowerRegion().
HandshakeLowering::MergeOpInfo HandshakeLowering::insertMerge | ( | Block * | block, |
Value | val, | ||
BackedgeBuilder & | edgeBuilder, | ||
ConversionPatternRewriter & | rewriter | ||
) |
Definition at line 286 of file CFToHandshake.cpp.
References circt::BackedgeBuilder::get(), and getBlockPredecessorCount().
HandshakeLowering::BlockOps HandshakeLowering::insertMergeOps | ( | HandshakeLowering::ValueMap & | mergePairs, |
BackedgeBuilder & | edgeBuilder, | ||
ConversionPatternRewriter & | rewriter | ||
) |
Definition at line 359 of file CFToHandshake.cpp.
LogicalResult HandshakeLowering::loopNetworkRewriting | ( | ConversionPatternRewriter & | rewriter | ) |
Definition at line 846 of file CFToHandshake.cpp.
Referenced by circt::handshake::lowerRegion().
LogicalResult HandshakeLowering::replaceCallOps | ( | ConversionPatternRewriter & | rewriter | ) |
An instance is activated whenever control arrives at the basic block of the source callOp.
Definition at line 1628 of file CFToHandshake.cpp.
Referenced by circt::handshake::lowerRegion().
LogicalResult HandshakeLowering::replaceMemoryOps | ( | ConversionPatternRewriter & | rewriter, |
MemRefToMemoryAccessOp & | memRefOps | ||
) |
Definition at line 1269 of file CFToHandshake.cpp.
References assert(), getOpMemRef(), isMemoryOp(), and isValidMemrefType().
Referenced by circt::handshake::lowerRegion().
|
protected |
Definition at line 258 of file CFToHandshake.cpp.
References circt::maximizeSSA().
Referenced by setControlOnlyPath().
void HandshakeLowering::setBlockEntryControl | ( | Block * | block, |
Value | v | ||
) |
Definition at line 221 of file CFToHandshake.cpp.
Referenced by setControlOnlyPath().
|
inline |
Definition at line 77 of file CFToHandshake.h.
References assert(), r, runSSAMaximization(), and setBlockEntryControl().
void HandshakeLowering::setMemOpControlInputs | ( | ConversionPatternRewriter & | rewriter, |
ArrayRef< Operation * > | memOps, | ||
Operation * | memOp, | ||
int | offset, | ||
ArrayRef< int > | cntrlInd | ||
) |
Definition at line 1475 of file CFToHandshake.cpp.
References addValueToOperands().
|
private |
Definition at line 164 of file CFToHandshake.h.
|
protected |
Definition at line 158 of file CFToHandshake.h.
Referenced by getContext(), getRegion(), and setControlOnlyPath().
|
protected |
Start point of the control-only network.
Definition at line 161 of file CFToHandshake.h.