LLVM API Documentation
#include "llvm/Transforms/Scalar.h"
#include "llvm/ADT/Statistic.h"
#include "llvm/Analysis/AliasAnalysis.h"
#include "llvm/Analysis/AliasSetTracker.h"
#include "llvm/Analysis/ConstantFolding.h"
#include "llvm/Analysis/LoopInfo.h"
#include "llvm/Analysis/LoopPass.h"
#include "llvm/Analysis/ScalarEvolution.h"
#include "llvm/Analysis/ValueTracking.h"
#include "llvm/IR/CFG.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DataLayout.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Dominators.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/IntrinsicInst.h"
#include "llvm/IR/LLVMContext.h"
#include "llvm/IR/Metadata.h"
#include "llvm/IR/PredIteratorCache.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/raw_ostream.h"
#include "llvm/Target/TargetLibraryInfo.h"
#include "llvm/Transforms/Utils/Local.h"
#include "llvm/Transforms/Utils/LoopUtils.h"
#include "llvm/Transforms/Utils/SSAUpdater.h"
#include <algorithm>
Go to the source code of this file.
Defines | |
#define | DEBUG_TYPE "licm" |
Functions | |
STATISTIC (NumSunk,"Number of instructions sunk out of loop") | |
STATISTIC (NumHoisted,"Number of instructions hoisted out of loop") | |
STATISTIC (NumMovedLoads,"Number of load insts hoisted or sunk") | |
STATISTIC (NumMovedCalls,"Number of call insts hoisted or sunk") | |
STATISTIC (NumPromoted,"Number of memory locations promoted to registers") | |
static bool | isTriviallyReplacablePHI (PHINode &PN, Instruction &I) |
Returns true if a PHINode is a trivially replaceable with an Instruction. | |
Variables | |
static cl::opt< bool > | DisablePromotion ("disable-licm-promotion", cl::Hidden, cl::desc("Disable memory promotion in LICM pass")) |
#define DEBUG_TYPE "licm" |
static bool isTriviallyReplacablePHI | ( | PHINode & | PN, |
Instruction & | I | ||
) | [static] |
Returns true if a PHINode is a trivially replaceable with an Instruction.
This is true when all incoming values are that instruction. This pattern occurs most often with LCSSA PHI nodes.
Definition at line 502 of file LICM.cpp.
References llvm::PHINode::getIncomingValue(), llvm::PHINode::getNumIncomingValues(), and I.
STATISTIC | ( | NumSunk | , |
"Number of instructions sunk out of loop" | |||
) |
STATISTIC | ( | NumHoisted | , |
"Number of instructions hoisted out of loop" | |||
) |
STATISTIC | ( | NumMovedLoads | , |
"Number of load insts hoisted or sunk" | |||
) |
STATISTIC | ( | NumMovedCalls | , |
"Number of call insts hoisted or sunk" | |||
) |
STATISTIC | ( | NumPromoted | , |
"Number of memory locations promoted to registers" | |||
) |