MLIR
16.0.0git
|
#include "mlir/IR/Dominance.h"
Public Member Functions | |
DominanceInfoBase (Operation *op=nullptr) | |
DominanceInfoBase (DominanceInfoBase &&)=default | |
DominanceInfoBase & | operator= (DominanceInfoBase &&)=default |
~DominanceInfoBase () | |
DominanceInfoBase (const DominanceInfoBase &)=delete | |
DominanceInfoBase & | operator= (const DominanceInfoBase &)=delete |
void | invalidate () |
Invalidate dominance info. More... | |
void | invalidate (Region *region) |
Block * | findNearestCommonDominator (Block *a, Block *b) const |
Finds the nearest common dominator block for the two given blocks a and b. More... | |
DominanceInfoNode * | getRootNode (Region *region) |
Get the root dominance node of the given region. More... | |
DominanceInfoNode * | getNode (Block *a) |
Return the dominance node from the Region containing block A. More... | |
bool | isReachableFromEntry (Block *a) const |
Return true if the specified block is reachable from the entry block of its region. More... | |
bool | hasSSADominance (Block *block) const |
Return true if operations in the specified block are known to obey SSA dominance requirements. More... | |
bool | hasSSADominance (Region *region) const |
Return true if operations in the specified block are known to obey SSA dominance requirements. More... | |
DomTree & | getDomTree (Region *region) const |
Protected Types | |
using | super = DominanceInfoBase< IsPostDom > |
Protected Member Functions | |
llvm::PointerIntPair< DomTree *, 1, bool > | getDominanceInfo (Region *region, bool needsDomTree) const |
Return the dom tree and "hasSSADominance" bit for the given region. More... | |
bool | properlyDominates (Block *a, Block *b) const |
Return true if the specified block A properly dominates block B. More... | |
Protected Attributes | |
DenseMap< Region *, llvm::PointerIntPair< DomTree *, 1, bool > > | dominanceInfos |
A mapping of regions to their base dominator tree and a cached "hasSSADominance" bit. More... | |
Definition at line 34 of file Dominance.h.
|
protected |
Definition at line 92 of file Dominance.h.
|
inline |
Definition at line 38 of file Dominance.h.
|
default |
DominanceInfoBase::~DominanceInfoBase | ( | ) |
Definition at line 32 of file Dominance.cpp.
|
delete |
Block * DominanceInfoBase::findNearestCommonDominator | ( | Block * | a, |
Block * | b | ||
) | const |
Finds the nearest common dominator block for the two given blocks a and b.
If no common dominator can be found, this function will return nullptr.
Definition at line 176 of file Dominance.cpp.
|
protected |
Return the dom tree and "hasSSADominance" bit for the given region.
The DomTree will be null for single-block regions. This lazily constructs the DomTree on demand when needsDomTree=true.
Definition at line 41 of file Dominance.cpp.
|
inline |
Definition at line 85 of file Dominance.h.
|
inline |
Return the dominance node from the Region containing block A.
This only works for multi-block regions.
Definition at line 66 of file Dominance.h.
|
inline |
Get the root dominance node of the given region.
Note that this operation is only defined for multi-block regions!
Definition at line 58 of file Dominance.h.
|
inline |
Return true if operations in the specified block are known to obey SSA dominance requirements.
False if the block is a graph region or unknown.
Definition at line 76 of file Dominance.h.
|
inline |
Return true if operations in the specified block are known to obey SSA dominance requirements.
False if the block is a graph region or unknown.
Definition at line 81 of file Dominance.h.
|
inline |
Invalidate dominance info.
This can be used by clients that make major changes to the CFG and don't have a good way to update it.
Definition at line 48 of file Dominance.h.
|
inline |
Definition at line 49 of file Dominance.h.
bool DominanceInfoBase::isReachableFromEntry | ( | Block * | a | ) | const |
Return true if the specified block is reachable from the entry block of its region.
Definition at line 232 of file Dominance.cpp.
Referenced by diagnoseInvalidOperandDominance().
|
default |
|
delete |
|
protected |
Return true if the specified block A properly dominates block B.
Definition at line 202 of file Dominance.cpp.
|
mutableprotected |
A mapping of regions to their base dominator tree and a cached "hasSSADominance" bit.
This map does not contain dominator trees for single block CFG regions, but we do want to cache the "hasSSADominance" bit for them. We may also not have computed the DomTree yet. In either case, the DomTree is just null.
Definition at line 110 of file Dominance.h.