LLVM  3.7.0
Classes | Namespaces | Macros | Functions | Variables
CodeGen/Passes.h File Reference
#include "llvm/Pass.h"
#include "llvm/Target/TargetMachine.h"
#include <functional>
#include <string>
Include dependency graph for CodeGen/Passes.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  llvm::IdentifyingPassPtr
 Discriminated union of Pass ID types. More...
 
struct  llvm::isPodLike< IdentifyingPassPtr >
 
class  llvm::TargetPassConfig
 Target-Independent Code Generator Pass Configuration Options. More...
 

Namespaces

 llvm
 Compute iterated dominance frontiers using a linear time algorithm.
 
 llvm::legacy
 

Macros

#define INITIALIZE_TM_PASS_BEGIN   INITIALIZE_PASS_BEGIN
 Target machine pass initializer for passes with dependencies. More...
 
#define INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis)
 Target machine pass initializer for passes with dependencies. More...
 
#define INITIALIZE_TM_PASS(passName, arg, name, cfg, analysis)
 This initializer registers TargetMachine constructor, so the pass being initialized can use target dependent interfaces. More...
 

Functions

FunctionPass * llvm::createAtomicExpandPass (const TargetMachine *TM)
 
FunctionPass * llvm::createUnreachableBlockEliminationPass ()
 createUnreachableBlockEliminationPass - The LLVM code generator does not work well with unreachable basic blocks (what live ranges make sense for a block that cannot be reached?). More...
 
MachineFunctionPass * llvm::createMachineFunctionPrinterPass (raw_ostream &OS, const std::string &Banner="")
 MachineFunctionPrinter pass - This pass prints out the machine function to the given stream as a debugging tool. More...
 
MachineFunctionPassllvm::createPrintMIRPass (raw_ostream &OS)
 MIRPrinting pass - this pass prints out the LLVM IR into the given stream using the MIR serialization format. More...
 
FunctionPass * llvm::createCodeGenPreparePass (const TargetMachine *TM=nullptr)
 createCodeGenPreparePass - Transform the code to expose more pattern matching during instruction selection. More...
 
FunctionPassllvm::createFastRegisterAllocator ()
 FastRegisterAllocation Pass - This pass register allocates as fast as possible. More...
 
FunctionPassllvm::createBasicRegisterAllocator ()
 BasicRegisterAllocation Pass - This pass implements a degenerate global register allocator using the basic regalloc framework. More...
 
FunctionPassllvm::createGreedyRegisterAllocator ()
 Greedy register allocation pass - This pass implements a global register allocator for optimized builds. More...
 
FunctionPassllvm::createDefaultPBQPRegisterAllocator ()
 PBQPRegisterAllocation Pass - This pass implements the Partitioned Boolean Quadratic Prograaming (PBQP) based register allocator. More...
 
FunctionPassllvm::createIfConverter (std::function< bool(const Function &)> Ftor)
 
FunctionPass * llvm::createGCLoweringPass ()
 GCLowering Pass - Used by gc.root to perform its default lowering operations. More...
 
FunctionPassllvm::createShadowStackGCLoweringPass ()
 ShadowStackGCLowering - Implements the custom lowering mechanism used by the shadow stack GC. More...
 
FunctionPassllvm::createGCInfoPrinter (raw_ostream &OS)
 Creates a pass to print GC metadata. More...
 
FunctionPass * llvm::createStackProtectorPass (const TargetMachine *TM)
 createStackProtectorPass - This pass adds stack protectors to functions. More...
 
FunctionPass * llvm::createMachineVerifierPass (const std::string &Banner)
 createMachineVerifierPass - This pass verifies cenerated machine code instructions for correctness. More...
 
FunctionPassllvm::createDwarfEHPass (const TargetMachine *TM)
 createDwarfEHPass - This pass mulches exception handling code into a form adapted to code generation. More...
 
FunctionPass * llvm::createWinEHPass (const TargetMachine *TM)
 createWinEHPass - Prepares personality functions used by MSVC on Windows, in addition to the Itanium LSDA based personalities. More...
 
FunctionPass * llvm::createSjLjEHPreparePass ()
 createSjLjEHPreparePass - This pass adapts exception handling code to use the GCC-style builtin setjmp/longjmp (sjlj) to handling EH control flow. More...
 
FunctionPassllvm::createExecutionDependencyFixPass (const TargetRegisterClass *RC)
 createExecutionDependencyFixPass - This pass fixes execution time problems with dependent instructions, such as switching execution domains to match. More...
 
FunctionPassllvm::createUnpackMachineBundles (std::function< bool(const Function &)> Ftor)
 
ModulePass * llvm::createJumpInstrTablesPass ()
 createJumpInstrTables - This pass creates jump-instruction tables. More...
 
ModulePass * llvm::createForwardControlFlowIntegrityPass ()
 createForwardControlFlowIntegrityPass - This pass adds control-flow integrity. More...
 
FunctionPass * llvm::createInterleavedAccessPass (const TargetMachine *TM)
 InterleavedAccess Pass - This pass identifies and matches interleaved memory accesses to target specific intrinsics. More...
 

Variables

char & llvm::AtomicExpandID = AtomicExpand::ID
 AtomicExpandID – Lowers atomic operations in terms of either cmpxchg load-linked/store-conditional loops. More...
 
char & llvm::MachineLoopInfoID = MachineLoopInfo::ID
 MachineLoopInfo - This pass is a loop analysis pass. More...
 
char & llvm::MachineDominatorsID
 MachineDominators - This pass is a machine dominators analysis pass. More...
 
char & llvm::MachineDominanceFrontierID = MachineDominanceFrontier::ID
 MachineDominanaceFrontier - This pass is a machine dominators analysis pass. More...
 
char & llvm::EdgeBundlesID
 EdgeBundles analysis - Bundle machine CFG edges. More...
 
char & llvm::LiveVariablesID = LiveVariables::ID
 LiveVariables pass - This pass computes the set of blocks in which each variable is life and sets machine operand kill flags. More...
 
char & llvm::PHIEliminationID = PHIElimination::ID
 PHIElimination - This pass eliminates machine instruction PHI nodes by inserting copy instructions. More...
 
char & llvm::LiveIntervalsID = LiveIntervals::ID
 LiveIntervals - This analysis keeps track of the live ranges of virtual and physical registers. More...
 
char & llvm::LiveStacksID = LiveStacks::ID
 LiveStacks pass. An analysis keeping track of the liveness of stack slots. More...
 
char & llvm::TwoAddressInstructionPassID = TwoAddressInstructionPass::ID
 TwoAddressInstruction - This pass reduces two-address instructions to use two operands. More...
 
char & llvm::ProcessImplicitDefsID = ProcessImplicitDefs::ID
 ProcessImpicitDefs pass - This pass removes IMPLICIT_DEFs. More...
 
char & llvm::RegisterCoalescerID = RegisterCoalescer::ID
 RegisterCoalescer - This pass merges live ranges to eliminate copies. More...
 
char & llvm::MachineSchedulerID = MachineScheduler::ID
 MachineScheduler - This pass schedules machine instructions. More...
 
char & llvm::PostMachineSchedulerID = PostMachineScheduler::ID
 PostMachineScheduler - This pass schedules machine instructions postRA. More...
 
char & llvm::SpillPlacementID = SpillPlacement::ID
 SpillPlacement analysis. More...
 
char & llvm::ShrinkWrapID = ShrinkWrap::ID
 ShrinkWrap pass. Look for the best place to insert save and restore. More...
 
char & llvm::VirtRegRewriterID = VirtRegRewriter::ID
 VirtRegRewriter pass. More...
 
char & llvm::UnreachableMachineBlockElimID
 UnreachableMachineBlockElimination - This pass removes unreachable machine basic blocks. More...
 
char & llvm::DeadMachineInstructionElimID = DeadMachineInstructionElim::ID
 DeadMachineInstructionElim - This pass removes dead machine instructions. More...
 
char & llvm::PrologEpilogCodeInserterID = PEI::ID
 PrologEpilogCodeInserter - This pass inserts prolog and epilog code, and eliminates abstract frame references. More...
 
char & llvm::ExpandPostRAPseudosID = ExpandPostRA::ID
 ExpandPostRAPseudos - This pass expands pseudo instructions after register allocation. More...
 
char & llvm::PostRASchedulerID = PostRAScheduler::ID
 createPostRAScheduler - This pass performs post register allocation scheduling. More...
 
char & llvm::BranchFolderPassID = BranchFolderPass::ID
 BranchFolding - This pass performs machine code CFG based optimizations to delete branches to branches, eliminate branches to successor blocks (creating fall throughs), and eliminating branches over branches. More...
 
char & llvm::MachineFunctionPrinterPassID = MachineFunctionPrinterPass::ID
 MachineFunctionPrinterPass - This pass prints out MachineInstr's. More...
 
char & llvm::MIRPrintingPassID = MIRPrintingPass::ID
 MIRPrintingPass - this pass prints out the LLVM IR using the MIR serialization format. More...
 
char & llvm::TailDuplicateID = TailDuplicatePass::ID
 TailDuplicate - Duplicate blocks with unconditional branches into tails of their predecessors. More...
 
char & llvm::MachineTraceMetricsID = MachineTraceMetrics::ID
 MachineTraceMetrics - This pass computes critical path and CPU resource usage in an ensemble of traces. More...
 
char & llvm::EarlyIfConverterID = EarlyIfConverter::ID
 EarlyIfConverter - This pass performs if-conversion on SSA form by inserting cmov instructions. More...
 
char & llvm::MachineCombinerID = MachineCombiner::ID
 This pass performs instruction combining using trace metrics to estimate critical-path and resource depth. More...
 
char & llvm::StackColoringID = StackColoring::ID
 StackSlotColoring - This pass performs stack coloring and merging. More...
 
char & llvm::IfConverterID = IfConverter::ID
 IfConverter - This pass performs machine code if conversion. More...
 
char & llvm::MachineBlockPlacementID = MachineBlockPlacement::ID
 MachineBlockPlacement - This pass places basic blocks based on branch probabilities. More...
 
char & llvm::MachineBlockPlacementStatsID = MachineBlockPlacementStats::ID
 MachineBlockPlacementStats - This pass collects statistics about the basic block placement using branch probabilities and block frequency information. More...
 
char & llvm::GCMachineCodeAnalysisID = GCMachineCodeAnalysis::ID
 GCMachineCodeAnalysis - Target-independent pass to mark safe points in machine code. More...
 
char & llvm::MachineCSEID = MachineCSE::ID
 MachineCSE - This pass performs global CSE on machine instructions. More...
 
char & llvm::ImplicitNullChecksID = ImplicitNullChecks::ID
 ImplicitNullChecks - This pass folds null pointer checks into nearby memory operations. More...
 
char & llvm::MachineLICMID = MachineLICM::ID
 MachineLICM - This pass performs LICM on machine instructions. More...
 
char & llvm::MachineSinkingID = MachineSinking::ID
 MachineSinking - This pass performs sinking on machine instructions. More...
 
char & llvm::MachineCopyPropagationID = MachineCopyPropagation::ID
 MachineCopyPropagation - This pass performs copy propagation on machine instructions. More...
 
char & llvm::PeepholeOptimizerID = PeepholeOptimizer::ID
 PeepholeOptimizer - This pass performs peephole optimizations - like extension and comparison eliminations. More...
 
char & llvm::OptimizePHIsID = OptimizePHIs::ID
 OptimizePHIs - This pass optimizes machine instruction PHIs to take advantage of opportunities created during DAG legalization. More...
 
char & llvm::StackSlotColoringID = StackSlotColoring::ID
 StackSlotColoring - This pass performs stack slot coloring. More...
 
char & llvm::LocalStackSlotAllocationID = LocalStackSlotPass::ID
 LocalStackSlotAllocation - This pass assigns local frame indices to stack slots relative to one another and allocates base registers to access them when it is estimated by the target to be out of range of normal frame pointer or stack pointer index addressing. More...
 
char & llvm::ExpandISelPseudosID = ExpandISelPseudos::ID
 ExpandISelPseudos - This pass expands pseudo-instructions. More...
 
char & llvm::UnpackMachineBundlesID = UnpackMachineBundles::ID
 UnpackMachineBundles - This pass unpack machine instruction bundles. More...
 
char & llvm::FinalizeMachineBundlesID = FinalizeMachineBundles::ID
 FinalizeMachineBundles - This pass finalize machine instruction bundles (created earlier, e.g. More...
 
char & llvm::StackMapLivenessID = StackMapLiveness::ID
 StackMapLiveness - This pass analyses the register live-out set of stackmap/patchpoint intrinsics and attaches the calculated information to the intrinsic for later emission to the StackMap. More...
 

Macro Definition Documentation

#define INITIALIZE_TM_PASS (   passName,
  arg,
  name,
  cfg,
  analysis 
)
Value:
INITIALIZE_TM_PASS_BEGIN(passName, arg, name, cfg, analysis) \
INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis)
#define INITIALIZE_TM_PASS_END(passName, arg, name, cfg, analysis)
Target machine pass initializer for passes with dependencies.
#define INITIALIZE_TM_PASS_BEGIN
Target machine pass initializer for passes with dependencies.
static const char * name

This initializer registers TargetMachine constructor, so the pass being initialized can use target dependent interfaces.

Please do not move this macro to be together with INITIALIZE_PASS, which is a complete target independent initializer, and we don't want to make libScalarOpts depend on libCodeGen.

Definition at line 677 of file CodeGen/Passes.h.

#define INITIALIZE_TM_PASS_BEGIN   INITIALIZE_PASS_BEGIN

Target machine pass initializer for passes with dependencies.

Use with INITIALIZE_TM_PASS_END.

Definition at line 657 of file CodeGen/Passes.h.

#define INITIALIZE_TM_PASS_END (   passName,
  arg,
  name,
  cfg,
  analysis 
)
Value:
PassInfo *PI = new PassInfo(name, arg, & passName ::ID, \
PassInfo::NormalCtor_t(callDefaultCtor< passName >), cfg, analysis, \
PassInfo::TargetMachineCtor_t(callTargetMachineCtor< passName >)); \
Registry.registerPass(*PI, true); \
return PI; \
} \
void llvm::initialize##passName##Pass(PassRegistry &Registry) { \
CALL_ONCE_INITIALIZATION(initialize##passName##PassOnce) \
}
static void initialize(TargetLibraryInfoImpl &TLI, const Triple &T, const char *const *StandardNames)
initialize - Initialize the set of available library functions based on the specified target triple...
aarch64 type AArch64 Type Promotion Pass
#define CALL_ONCE_INITIALIZATION(function)
Definition: PassSupport.h:36
static const char * name

Target machine pass initializer for passes with dependencies.

Use with INITIALIZE_TM_PASS_BEGIN.

Definition at line 661 of file CodeGen/Passes.h.