9 #ifndef MLIR_ANALYSIS_SLICEANALYSIS_H_
10 #define MLIR_ANALYSIS_SLICEANALYSIS_H_
17 #include "llvm/ADT/SetVector.h"
143 const BackwardSliceOptions &
options = {});
148 const BackwardSliceOptions &
options = {});
227 SetVector<Operation *>
228 getSlice(Operation *op,
const BackwardSliceOptions &backwardSliceOptions = {},
260 SmallVectorImpl<Operation *> &combinerOps);
static llvm::ManagedStatic< PassManagerOptions > options
Operation is the basic unit of execution within MLIR.
Include the generated interface declarations.
SliceOptions::TransitiveFilter TransitiveFilter
void getBackwardSlice(Operation *op, SetVector< Operation * > *backwardSlice, const BackwardSliceOptions &options={})
Fills backwardSlice with the computed backward slice (i.e.
SliceOptions ForwardSliceOptions
Value matchReduction(ArrayRef< BlockArgument > iterCarriedArgs, unsigned redPos, SmallVectorImpl< Operation * > &combinerOps)
Utility to match a generic reduction given a list of iteration-carried arguments, iterCarriedArgs and...
SetVector< Operation * > getSlice(Operation *op, const BackwardSliceOptions &backwardSliceOptions={}, const ForwardSliceOptions &forwardSliceOptions={})
Iteratively computes backward slices and forward slices until a fixed point is reached.
void getForwardSlice(Operation *op, SetVector< Operation * > *forwardSlice, const ForwardSliceOptions &options={})
Fills forwardSlice with the computed forward slice (i.e.
bool omitUsesFromAbove
When omitUsesFromAbove is true, the backward slice computation omits traversing values that are captu...
bool omitBlockArguments
When omitBlockArguments is true, the backward slice computation omits traversing any block arguments.
std::function< bool(Operation *)> TransitiveFilter
Type of the condition to limit the propagation of transitive use-defs.
bool inclusive
Include the top level op in the slice.
SliceOptions(TransitiveFilter filter)