LLVM  9.0.0svn
Typedefs | Functions | Variables
LoopInfo.cpp File Reference
#include "llvm/Analysis/LoopInfo.h"
#include "llvm/ADT/DepthFirstIterator.h"
#include "llvm/ADT/ScopeExit.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/Analysis/IVDescriptors.h"
#include "llvm/Analysis/LoopInfoImpl.h"
#include "llvm/Analysis/LoopIterator.h"
#include "llvm/Analysis/MemorySSA.h"
#include "llvm/Analysis/MemorySSAUpdater.h"
#include "llvm/Analysis/ScalarEvolutionExpressions.h"
#include "llvm/Analysis/ValueTracking.h"
#include "llvm/Config/llvm-config.h"
#include "llvm/IR/CFG.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DebugLoc.h"
#include "llvm/IR/Dominators.h"
#include "llvm/IR/IRPrintingPasses.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/LLVMContext.h"
#include "llvm/IR/Metadata.h"
#include "llvm/IR/PassManager.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
Include dependency graph for LoopInfo.cpp:

Go to the source code of this file.

Typedefs

using Direction = Loop::LoopBounds::Direction
 

Functions

static ICmpInstgetLatchCmpInst (const Loop &L)
 Get the latch condition instruction. More...
 
static ValuefindFinalIVValue (const Loop &L, const PHINode &IndVar, const Instruction &StepInst)
 Return the final value of the loop induction variable if found. More...
 
static bool isBlockInLCSSAForm (const Loop &L, const BasicBlock &BB, DominatorTree &DT)
 
 INITIALIZE_PASS_BEGIN (LoopInfoWrapperPass, "loops", "Natural Loop Information", true, true) INITIALIZE_PASS_END(LoopInfoWrapperPass
 

Variables

static cl::opt< bool, trueVerifyLoopInfoX ("verify-loop-info", cl::location(VerifyLoopInfo), cl::Hidden, cl::desc("Verify loop info (time consuming)"))
 
 loops
 
Natural Loop Information
 
Natural Loop true
 

Typedef Documentation

◆ Direction

Definition at line 226 of file LoopInfo.cpp.

Function Documentation

◆ findFinalIVValue()

static Value* findFinalIVValue ( const Loop L,
const PHINode IndVar,
const Instruction StepInst 
)
static

Return the final value of the loop induction variable if found.

Definition at line 180 of file LoopInfo.cpp.

References getLatchCmpInst(), and llvm::User::getOperand().

Referenced by llvm::Loop::LoopBounds::getBounds().

◆ getLatchCmpInst()

static ICmpInst* getLatchCmpInst ( const Loop L)
static

Get the latch condition instruction.

Definition at line 170 of file LoopInfo.cpp.

References llvm::LoopBase< BlockT, LoopT >::getLoopLatch().

Referenced by findFinalIVValue(), and llvm::Loop::getInductionVariable().

◆ INITIALIZE_PASS_BEGIN()

INITIALIZE_PASS_BEGIN ( LoopInfoWrapperPass  ,
"loops"  ,
"Natural Loop Information ,
true  ,
true   
)

◆ isBlockInLCSSAForm()

static bool isBlockInLCSSAForm ( const Loop L,
const BasicBlock BB,
DominatorTree DT 
)
static

Variable Documentation

◆ Information

Natural Loop Information

Definition at line 1016 of file LoopInfo.cpp.

◆ loops

loops

◆ true

Natural Loop true

Definition at line 1016 of file LoopInfo.cpp.

◆ VerifyLoopInfoX

cl::opt<bool, true> VerifyLoopInfoX("verify-loop-info", cl::location(VerifyLoopInfo), cl::Hidden, cl::desc("Verify loop info (time consuming)"))
static