Polly 19.0.0git
Classes | Macros | Functions
ScopHelper.cpp File Reference
#include "polly/Support/ScopHelper.h"
#include "polly/Options.h"
#include "polly/ScopInfo.h"
#include "polly/Support/SCEVValidator.h"
#include "llvm/Analysis/LoopInfo.h"
#include "llvm/Analysis/RegionInfo.h"
#include "llvm/Analysis/ScalarEvolution.h"
#include "llvm/Analysis/ScalarEvolutionExpressions.h"
#include "llvm/Transforms/Utils/BasicBlockUtils.h"
#include "llvm/Transforms/Utils/LoopUtils.h"
#include "llvm/Transforms/Utils/ScalarEvolutionExpander.h"
#include <optional>

Go to the source code of this file.

Classes

struct  ScopExpander
 The SCEVExpander will not generate any code for an existing SDiv/SRem instruction but just use it, if it is referenced as a SCEVUnknown. More...
 

Macros

#define DEBUG_TYPE   "polly-scop-helper"
 

Functions

static cl::list< std::string > DebugFunctions ("polly-debug-func", cl::desc("Allow calls to the specified functions in SCoPs even if their " "side-effects are unknown. This can be used to do debug output in " "Polly-transformed code."), cl::Hidden, cl::CommaSeparated, cl::cat(PollyCategory))
 
static void simplifyRegionEntry (Region *R, DominatorTree *DT, LoopInfo *LI, RegionInfo *RI)
 
static void simplifyRegionExit (Region *R, DominatorTree *DT, LoopInfo *LI, RegionInfo *RI)
 
static BasicBlock * splitBlock (BasicBlock *Old, Instruction *SplitPt, DominatorTree *DT, llvm::LoopInfo *LI, RegionInfo *RI)
 
static bool hasVariantIndex (GetElementPtrInst *Gep, Loop *L, Region &R, ScalarEvolution &SE)
 
static bool hasDebugCall (BasicBlock *BB)
 
static MDNode * findNamedMetadataNode (MDNode *LoopMD, StringRef Name)
 Find a property in a LoopID.
 
static std::optional< const MDOperand * > findNamedMetadataArg (MDNode *LoopID, StringRef Name)
 
static std::optional< bool > getOptionalBoolLoopAttribute (MDNode *LoopID, StringRef Name)
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "polly-scop-helper"

Definition at line 29 of file ScopHelper.cpp.

Function Documentation

◆ DebugFunctions()

static cl::list< std::string > DebugFunctions ( "polly-debug-func"  ,
cl::desc("Allow calls to the specified functions in SCoPs even if their " "side-effects are unknown. This can be used to do debug output in " "Polly-transformed code.")  ,
cl::Hidden  ,
cl::CommaSeparated  ,
cl::cat(PollyCategory  
)
static

Referenced by polly::hasDebugCall().

◆ findNamedMetadataArg()

static std::optional< const MDOperand * > findNamedMetadataArg ( MDNode *  LoopID,
StringRef  Name 
)
static

Definition at line 705 of file ScopHelper.cpp.

References findNamedMetadataNode().

◆ findNamedMetadataNode()

static MDNode * findNamedMetadataNode ( MDNode *  LoopMD,
StringRef  Name 
)
static

Find a property in a LoopID.

Definition at line 688 of file ScopHelper.cpp.

References X().

Referenced by findNamedMetadataArg(), and getOptionalBoolLoopAttribute().

◆ getOptionalBoolLoopAttribute()

static std::optional< bool > getOptionalBoolLoopAttribute ( MDNode *  LoopID,
StringRef  Name 
)
static

Definition at line 735 of file ScopHelper.cpp.

References findNamedMetadataNode().

◆ hasDebugCall()

static bool hasDebugCall ( BasicBlock *  BB)
static

Definition at line 658 of file ScopHelper.cpp.

References polly::isDebugCall().

Referenced by polly::hasDebugCall().

◆ hasVariantIndex()

static bool hasVariantIndex ( GetElementPtrInst *  Gep,
Loop *  L,
Region &  R,
ScalarEvolution &  SE 
)
static

Definition at line 508 of file ScopHelper.cpp.

◆ simplifyRegionEntry()

static void simplifyRegionEntry ( Region *  R,
DominatorTree *  DT,
LoopInfo *  LI,
RegionInfo *  RI 
)
static

Definition at line 41 of file ScopHelper.cpp.

References assert, and polly::Entry.

◆ simplifyRegionExit()

static void simplifyRegionExit ( Region *  R,
DominatorTree *  DT,
LoopInfo *  LI,
RegionInfo *  RI 
)
static

Definition at line 105 of file ScopHelper.cpp.

References assert.

◆ splitBlock()

static BasicBlock * splitBlock ( BasicBlock *  Old,
Instruction *  SplitPt,
DominatorTree *  DT,
llvm::LoopInfo *  LI,
RegionInfo *  RI 
)
static

Definition at line 168 of file ScopHelper.cpp.

References assert.