17 #ifndef MLIR_ANALYSIS_LIVENESS_H 18 #define MLIR_ANALYSIS_LIVENESS_H 23 #include "llvm/ADT/ArrayRef.h" 24 #include "llvm/ADT/DenseMap.h" 25 #include "llvm/ADT/SmallPtrSet.h" 30 class LivenessBlockInfo;
85 void print(raw_ostream &os)
const;
118 bool isLiveIn(
Value value)
const;
121 bool isLiveOut(
Value value)
const;
148 #endif // MLIR_ANALYSIS_LIVENESS_H Definition: InferTypeOpInterface.cpp:20
Block * getBlock() const
Returns the underlying block.
Definition: Liveness.h:107
Definition: Operation.h:27
Block represents an ordered list of Operations.
Definition: Block.h:21
This class represents liveness information on block level.
Definition: Liveness.h:100
void print(raw_ostream &os) const
Dumps the liveness information to the given stream.
Definition: Liveness.cpp:251
const ValueSetT & out() const
Definition: Liveness.h:115
const ValueSetT & getLiveOut(Block *block) const
Returns a reference to a set containing live-out values (unordered).
Definition: Liveness.cpp:226
Definition: Liveness.h:47
Operation * getOperation() const
Returns the operation this analysis was constructed from.
Definition: Liveness.h:59
const LivenessBlockInfo * getLiveness(Block *block) const
Gets liveness info (if any) for the block.
Definition: Liveness.cpp:215
void dump() const
Dumps the liveness information in a human readable format.
Definition: Liveness.cpp:248
std::vector< Operation * > OperationListT
Definition: Liveness.h:49
bool isLastUse(Value value, Operation *operation) const
Definition: Liveness.cpp:232
OperationListT resolveLiveness(Value value) const
Gets liveness info (if any) for the given value.
Definition: Liveness.cpp:167
const ValueSetT & in() const
Definition: Liveness.h:111
Liveness(Operation *op)
Definition: Liveness.cpp:146
const ValueSetT & getLiveIn(Block *block) const
Returns a reference to a set containing live-in values (unordered).
Definition: Liveness.cpp:221
SmallPtrSet< Value, 16 > ValueSetT
Definition: Liveness.h:51