Polly 19.0.0git
Namespaces | Macros | Functions
MatmulOptimizer.cpp File Reference
#include "polly/MatmulOptimizer.h"
#include "polly/DependenceInfo.h"
#include "polly/Options.h"
#include "polly/ScheduleTreeTransform.h"
#include "polly/ScopInfo.h"
#include "polly/ScopPass.h"
#include "polly/Simplify.h"
#include "polly/Support/GICHelper.h"
#include "polly/Support/ISLTools.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/Sequence.h"
#include "llvm/ADT/SetOperations.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/iterator_range.h"
#include "llvm/Analysis/TargetTransformInfo.h"
#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/Module.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/TypeSize.h"
#include "llvm/Support/raw_ostream.h"
#include "isl/ctx.h"
#include "isl/schedule_node.h"
#include "isl/schedule_type.h"
#include "isl/union_map.h"
#include "isl/union_set.h"
#include <algorithm>
#include <cassert>
#include <cmath>
#include <cstdint>
#include <string>
#include <vector>
#include "polly/Support/PollyDebug.h"

Go to the source code of this file.

Namespaces

namespace  llvm
 This file contains the declaration of the PolyhedralInfo class, which will provide an interface to expose polyhedral analysis information of Polly.
 

Macros

#define DEBUG_TYPE   "polly-opt-isl"
 

Functions

static cl::opt< int > LatencyVectorFma ("polly-target-latency-vector-fma", cl::desc("The minimal number of cycles between issuing two " "dependent consecutive vector fused multiply-add " "instructions."), cl::Hidden, cl::init(8), cl::cat(PollyCategory))
 
static cl::opt< int > ThroughputVectorFma ("polly-target-throughput-vector-fma", cl::desc("A throughput of the processor floating-point arithmetic units " "expressed in the number of vector fused multiply-add " "instructions per clock cycle."), cl::Hidden, cl::init(1), cl::cat(PollyCategory))
 
static cl::opt< int > FirstCacheLevelSize ("polly-target-1st-cache-level-size", cl::desc("The size of the first cache level specified in bytes."), cl::Hidden, cl::init(-1), cl::cat(PollyCategory))
 
static cl::opt< int > FirstCacheLevelDefaultSize ("polly-target-1st-cache-level-default-size", cl::desc("The default size of the first cache level specified in bytes" " (if not enough were provided by the TargetTransformInfo)."), cl::Hidden, cl::init(32768), cl::cat(PollyCategory))
 
static cl::opt< int > SecondCacheLevelSize ("polly-target-2nd-cache-level-size", cl::desc("The size of the second level specified in bytes."), cl::Hidden, cl::init(-1), cl::cat(PollyCategory))
 
static cl::opt< int > SecondCacheLevelDefaultSize ("polly-target-2nd-cache-level-default-size", cl::desc("The default size of the second cache level specified in bytes" " (if not enough were provided by the TargetTransformInfo)."), cl::Hidden, cl::init(262144), cl::cat(PollyCategory))
 
static cl::opt< int > FirstCacheLevelAssociativity ("polly-target-1st-cache-level-associativity", cl::desc("The associativity of the first cache level."), cl::Hidden, cl::init(-1), cl::cat(PollyCategory))
 
static cl::opt< int > FirstCacheLevelDefaultAssociativity ("polly-target-1st-cache-level-default-associativity", cl::desc("The default associativity of the first cache level" " (if not enough were provided by the TargetTransformInfo)."), cl::Hidden, cl::init(8), cl::cat(PollyCategory))
 
static cl::opt< int > SecondCacheLevelAssociativity ("polly-target-2nd-cache-level-associativity", cl::desc("The associativity of the second cache level."), cl::Hidden, cl::init(-1), cl::cat(PollyCategory))
 
static cl::opt< int > SecondCacheLevelDefaultAssociativity ("polly-target-2nd-cache-level-default-associativity", cl::desc("The default associativity of the second cache level" " (if not enough were provided by the TargetTransformInfo)."), cl::Hidden, cl::init(8), cl::cat(PollyCategory))
 
static cl::opt< int > VectorRegisterBitwidth ("polly-target-vector-register-bitwidth", cl::desc("The size in bits of a vector register (if not set, this " "information is taken from LLVM's target information."), cl::Hidden, cl::init(-1), cl::cat(PollyCategory))
 
static cl::opt< int > PollyPatternMatchingNcQuotient ("polly-pattern-matching-nc-quotient", cl::desc("Quotient that is obtained by dividing Nc, the parameter of the" "macro-kernel, by Nr, the parameter of the micro-kernel"), cl::Hidden, cl::init(256), cl::cat(PollyCategory))
 
static cl::opt< bool > PMBasedTCOpts ("polly-tc-opt", cl::desc("Perform optimizations of tensor contractions based " "on pattern matching"), cl::init(false), cl::ZeroOrMore, cl::cat(PollyCategory))
 
static cl::opt< bool > PMBasedMMMOpts ("polly-matmul-opt", cl::desc("Perform optimizations of matrix multiplications " "based on pattern matching"), cl::init(true), cl::ZeroOrMore, cl::cat(PollyCategory))
 
static cl::opt< int > OptComputeOut ("polly-tc-dependences-computeout", cl::desc("Bound the dependence analysis by a maximal amount of " "computational steps (0 means no bound)"), cl::Hidden, cl::init(500000), cl::ZeroOrMore, cl::cat(PollyCategory))
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "polly-opt-isl"

Definition at line 46 of file MatmulOptimizer.cpp.

Function Documentation

◆ FirstCacheLevelAssociativity()

static cl::opt< int > FirstCacheLevelAssociativity ( "polly-target-1st-cache-level-associativity"  ,
cl::desc("The associativity of the first cache level.")  ,
cl::Hidden  ,
cl::init(-1)  ,
cl::cat(PollyCategory  
)
static

◆ FirstCacheLevelDefaultAssociativity()

static cl::opt< int > FirstCacheLevelDefaultAssociativity ( "polly-target-1st-cache-level-default-associativity"  ,
cl::desc("The default associativity of the first cache level" " (if not enough were provided by the TargetTransformInfo).")  ,
cl::Hidden  ,
cl::init(8)  ,
cl::cat(PollyCategory  
)
static

◆ FirstCacheLevelDefaultSize()

static cl::opt< int > FirstCacheLevelDefaultSize ( "polly-target-1st-cache-level-default-size"  ,
cl::desc("The default size of the first cache level specified in bytes" " (if not enough were provided by the TargetTransformInfo).")  ,
cl::Hidden  ,
cl::init(32768)  ,
cl::cat(PollyCategory  
)
static

◆ FirstCacheLevelSize()

static cl::opt< int > FirstCacheLevelSize ( "polly-target-1st-cache-level-size"  ,
cl::desc("The size of the first cache level specified in bytes.")  ,
cl::Hidden  ,
cl::init(-1)  ,
cl::cat(PollyCategory  
)
static

◆ LatencyVectorFma()

static cl::opt< int > LatencyVectorFma ( "polly-target-latency-vector-fma"  ,
cl::desc("The minimal number of cycles between issuing two " "dependent consecutive vector fused multiply-add " "instructions.")  ,
cl::Hidden  ,
cl::init(8)  ,
cl::cat(PollyCategory  
)
static

◆ OptComputeOut()

static cl::opt< int > OptComputeOut ( "polly-tc-dependences-computeout"  ,
cl::desc("Bound the dependence analysis by a maximal amount of " "computational steps (0 means no bound)")  ,
cl::Hidden  ,
cl::init(500000)  ,
cl::ZeroOrMore  ,
cl::cat(PollyCategory  
)
static

◆ PMBasedMMMOpts()

static cl::opt< bool > PMBasedMMMOpts ( "polly-matmul-opt"  ,
cl::desc("Perform optimizations of matrix multiplications " "based on pattern matching")  ,
cl::init(true)  ,
cl::ZeroOrMore  ,
cl::cat(PollyCategory  
)
static

◆ PMBasedTCOpts()

static cl::opt< bool > PMBasedTCOpts ( "polly-tc-opt"  ,
cl::desc("Perform optimizations of tensor contractions based " "on pattern matching")  ,
cl::init(false)  ,
cl::ZeroOrMore  ,
cl::cat(PollyCategory  
)
static

◆ PollyPatternMatchingNcQuotient()

static cl::opt< int > PollyPatternMatchingNcQuotient ( "polly-pattern-matching-nc-quotient"  ,
cl::desc("Quotient that is obtained by dividing Nc, the parameter of the" "macro-kernel, by Nr, the parameter of the micro-kernel")  ,
cl::Hidden  ,
cl::init(256)  ,
cl::cat(PollyCategory  
)
static

◆ SecondCacheLevelAssociativity()

static cl::opt< int > SecondCacheLevelAssociativity ( "polly-target-2nd-cache-level-associativity"  ,
cl::desc("The associativity of the second cache level.")  ,
cl::Hidden  ,
cl::init(-1)  ,
cl::cat(PollyCategory  
)
static

◆ SecondCacheLevelDefaultAssociativity()

static cl::opt< int > SecondCacheLevelDefaultAssociativity ( "polly-target-2nd-cache-level-default-associativity"  ,
cl::desc("The default associativity of the second cache level" " (if not enough were provided by the TargetTransformInfo).")  ,
cl::Hidden  ,
cl::init(8)  ,
cl::cat(PollyCategory  
)
static

◆ SecondCacheLevelDefaultSize()

static cl::opt< int > SecondCacheLevelDefaultSize ( "polly-target-2nd-cache-level-default-size"  ,
cl::desc("The default size of the second cache level specified in bytes" " (if not enough were provided by the TargetTransformInfo).")  ,
cl::Hidden  ,
cl::init(262144)  ,
cl::cat(PollyCategory  
)
static

◆ SecondCacheLevelSize()

static cl::opt< int > SecondCacheLevelSize ( "polly-target-2nd-cache-level-size"  ,
cl::desc("The size of the second level specified in bytes.")  ,
cl::Hidden  ,
cl::init(-1)  ,
cl::cat(PollyCategory  
)
static

◆ ThroughputVectorFma()

static cl::opt< int > ThroughputVectorFma ( "polly-target-throughput-vector-fma"  ,
cl::desc("A throughput of the processor floating-point arithmetic units " "expressed in the number of vector fused multiply-add " "instructions per clock cycle.")  ,
cl::Hidden  ,
cl::init(1)  ,
cl::cat(PollyCategory  
)
static

◆ VectorRegisterBitwidth()

static cl::opt< int > VectorRegisterBitwidth ( "polly-target-vector-register-bitwidth"  )
static