MLIR: lib/Dialect/Bufferization/Transforms/BufferOptimizations.cpp File Reference (original) (raw)

Go to the source code of this file.

Namespaces
Macros
#define GEN_PASS_DEF_BUFFERHOISTINGPASS
#define GEN_PASS_DEF_BUFFERLOOPHOISTINGPASS
#define GEN_PASS_DEF_PROMOTEBUFFERSTOSTACKPASS
Functions
static bool isKnownControlFlowInterface (Operation *op)
Returns true if the given operation implements a known high-level region- based control-flow interface. More...
static bool isLoop (Operation *op)
Returns true if the given operation represents a loop by testing whether it implements the LoopLikeOpInterface or the RegionBranchOpInterface. More...
static bool isSequentialLoop (Operation *op)
Return whether the given operation is a loop with sequential execution semantics. More...
static bool allowAllocDominateBlockHoisting (Operation *op)
Returns true if the given operation implements the AllocationOpInterface and it supports the dominate block hoisting. More...
static bool allowAllocLoopHoisting (Operation *op)
Returns true if the given operation implements the AllocationOpInterface and it supports the loop hoisting. More...
static bool defaultIsSmallAlloc (Value alloc, unsigned maximumSizeInBytes, unsigned maxRankOfAllocatedMemRef)
Check if the size of the allocation is less than the given size. More...
static bool leavesAllocationScope (Region *parentRegion, const BufferViewFlowAnalysis::ValueSetT &aliases)
Checks whether the given aliases leave the allocation scope. More...
static bool hasAllocationScope (Value alloc, const BufferViewFlowAnalysis &aliasAnalysis)
Checks, if an automated allocation scope for a given alloc value exists. More...

GEN_PASS_DEF_BUFFERHOISTINGPASS

#define GEN_PASS_DEF_BUFFERHOISTINGPASS

GEN_PASS_DEF_BUFFERLOOPHOISTINGPASS

#define GEN_PASS_DEF_BUFFERLOOPHOISTINGPASS

GEN_PASS_DEF_PROMOTEBUFFERSTOSTACKPASS

#define GEN_PASS_DEF_PROMOTEBUFFERSTOSTACKPASS

allowAllocDominateBlockHoisting()

static bool allowAllocDominateBlockHoisting ( Operation * op) static

Returns true if the given operation implements the AllocationOpInterface and it supports the dominate block hoisting.

Definition at line 70 of file BufferOptimizations.cpp.

References mlir::Block.

allowAllocLoopHoisting()

static bool allowAllocLoopHoisting ( Operation * op) static

Returns true if the given operation implements the AllocationOpInterface and it supports the loop hoisting.

Definition at line 78 of file BufferOptimizations.cpp.

References mlir::Loop.

defaultIsSmallAlloc()

static bool defaultIsSmallAlloc ( Value alloc, unsigned maximumSizeInBytes, unsigned maxRankOfAllocatedMemRef ) static

hasAllocationScope()

isKnownControlFlowInterface()

static bool isKnownControlFlowInterface ( Operation * op) static

isLoop()

Returns true if the given operation represents a loop by testing whether it implements the LoopLikeOpInterface or the RegionBranchOpInterface.

In the case of a RegionBranchOpInterface, it checks all region-based control- flow edges for cycles.

Definition at line 47 of file BufferOptimizations.cpp.

Referenced by hasAllocationScope(), and isSequentialLoop().

isSequentialLoop()

static bool isSequentialLoop ( Operation * op) static

leavesAllocationScope()