MLIR  20.0.0git
Namespaces | Macros | Functions
AffineLoopInvariantCodeMotion.cpp File Reference
#include "mlir/Dialect/Affine/Passes.h"
#include "mlir/Analysis/SliceAnalysis.h"
#include "mlir/Dialect/Affine/Analysis/AffineAnalysis.h"
#include "mlir/Dialect/Affine/Analysis/AffineStructures.h"
#include "mlir/Dialect/Affine/Analysis/LoopAnalysis.h"
#include "mlir/Dialect/Affine/Analysis/Utils.h"
#include "mlir/Dialect/Affine/IR/AffineOps.h"
#include "mlir/Dialect/Affine/LoopUtils.h"
#include "mlir/Dialect/Affine/Utils.h"
#include "mlir/Dialect/Arith/IR/Arith.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/IR/AffineExpr.h"
#include "mlir/IR/AffineMap.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/Matchers.h"
#include "mlir/Interfaces/SideEffectInterfaces.h"
#include "llvm/ADT/DenseMap.h"
#include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
#include "mlir/Dialect/Affine/Passes.h.inc"

Go to the source code of this file.

Namespaces

 mlir
 Include the generated interface declarations.
 
 mlir::affine
 

Macros

#define GEN_PASS_DEF_AFFINELOOPINVARIANTCODEMOTION
 
#define DEBUG_TYPE   "licm"
 

Functions

static bool checkInvarianceOfNestedIfOps (AffineIfOp ifOp, Value indVar, ValueRange iterArgs, SmallPtrSetImpl< Operation * > &opsWithUsers, SmallPtrSetImpl< Operation * > &opsToHoist)
 
static bool isOpLoopInvariant (Operation &op, Value indVar, ValueRange iterArgs, SmallPtrSetImpl< Operation * > &opsWithUsers, SmallPtrSetImpl< Operation * > &opsToHoist)
 
static bool areAllOpsInTheBlockListInvariant (Region &blockList, Value indVar, ValueRange iterArgs, SmallPtrSetImpl< Operation * > &opsWithUsers, SmallPtrSetImpl< Operation * > &opsToHoist)
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "licm"

Definition at line 44 of file AffineLoopInvariantCodeMotion.cpp.

◆ GEN_PASS_DEF_AFFINELOOPINVARIANTCODEMOTION

#define GEN_PASS_DEF_AFFINELOOPINVARIANTCODEMOTION

Definition at line 39 of file AffineLoopInvariantCodeMotion.cpp.

Function Documentation

◆ areAllOpsInTheBlockListInvariant()

static bool areAllOpsInTheBlockListInvariant ( Region blockList,
Value  indVar,
ValueRange  iterArgs,
SmallPtrSetImpl< Operation * > &  opsWithUsers,
SmallPtrSetImpl< Operation * > &  opsToHoist 
)
static

◆ checkInvarianceOfNestedIfOps()

static bool checkInvarianceOfNestedIfOps ( AffineIfOp  ifOp,
Value  indVar,
ValueRange  iterArgs,
SmallPtrSetImpl< Operation * > &  opsWithUsers,
SmallPtrSetImpl< Operation * > &  opsToHoist 
)
static

Definition at line 190 of file AffineLoopInvariantCodeMotion.cpp.

References areAllOpsInTheBlockListInvariant().

Referenced by isOpLoopInvariant().

◆ isOpLoopInvariant()

static bool isOpLoopInvariant ( Operation op,
Value  indVar,
ValueRange  iterArgs,
SmallPtrSetImpl< Operation * > &  opsWithUsers,
SmallPtrSetImpl< Operation * > &  opsToHoist 
)
static