CIRCT  19.0.0git
Namespaces | Macros | Functions
LegalizeStateUpdate.cpp File Reference
#include "circt/Dialect/Arc/ArcOps.h"
#include "circt/Dialect/Arc/ArcPasses.h"
#include "mlir/Dialect/SCF/IR/SCF.h"
#include "mlir/IR/Dominance.h"
#include "mlir/IR/ImplicitLocOpBuilder.h"
#include "llvm/ADT/PointerIntPair.h"
#include "llvm/ADT/TypeSwitch.h"
#include "llvm/Support/Debug.h"
#include "circt/Dialect/Arc/ArcPasses.h.inc"
Include dependency graph for LegalizeStateUpdate.cpp:

Go to the source code of this file.

Namespaces

 circt
 The InstanceGraph op interface, see InstanceGraphInterface.td for more details.
 
 circt::arc
 

Macros

#define DEBUG_TYPE   "arc-legalize-state-update"
 
#define GEN_PASS_DEF_LEGALIZESTATEUPDATE
 

Functions

static bool isOpInteresting (Operation *op)
 Check if an operation partakes in state accesses. More...
 
static LogicalResult getAncestorOpsInCommonDominatorBlock (Operation *write, Operation **writeAncestor, Operation *read, Operation **readAncestor, DominanceInfo *domInfo)
 
static LogicalResult moveMemoryWritesAfterLastRead (Region &region, const DenseSet< Value > &memories, DominanceInfo *domInfo)
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "arc-legalize-state-update"

Definition at line 18 of file LegalizeStateUpdate.cpp.

◆ GEN_PASS_DEF_LEGALIZESTATEUPDATE

#define GEN_PASS_DEF_LEGALIZESTATEUPDATE

Definition at line 22 of file LegalizeStateUpdate.cpp.

Function Documentation

◆ getAncestorOpsInCommonDominatorBlock()

static LogicalResult getAncestorOpsInCommonDominatorBlock ( Operation *  write,
Operation **  writeAncestor,
Operation *  read,
Operation **  readAncestor,
DominanceInfo *  domInfo 
)
static

Definition at line 435 of file LegalizeStateUpdate.cpp.

Referenced by moveMemoryWritesAfterLastRead().

◆ isOpInteresting()

static bool isOpInteresting ( Operation *  op)
static

Check if an operation partakes in state accesses.

Definition at line 32 of file LegalizeStateUpdate.cpp.

◆ moveMemoryWritesAfterLastRead()

static LogicalResult moveMemoryWritesAfterLastRead ( Region &  region,
const DenseSet< Value > &  memories,
DominanceInfo *  domInfo 
)
static

Definition at line 463 of file LegalizeStateUpdate.cpp.

References getAncestorOpsInCommonDominatorBlock().