Home | History | Annotate | Download | only in Analysis
      1 //===-- llvm/Analysis/Passes.h - Constructors for analyses ------*- C++ -*-===//
      2 //
      3 //                     The LLVM Compiler Infrastructure
      4 //
      5 // This file is distributed under the University of Illinois Open Source
      6 // License. See LICENSE.TXT for details.
      7 //
      8 //===----------------------------------------------------------------------===//
      9 //
     10 // This header file defines prototypes for accessor functions that expose passes
     11 // in the analysis libraries.
     12 //
     13 //===----------------------------------------------------------------------===//
     14 
     15 #ifndef LLVM_ANALYSIS_PASSES_H
     16 #define LLVM_ANALYSIS_PASSES_H
     17 
     18 namespace llvm {
     19   class FunctionPass;
     20   class ImmutablePass;
     21   class LoopPass;
     22   class ModulePass;
     23   class Pass;
     24   class PassInfo;
     25   class LibCallInfo;
     26 
     27   //===--------------------------------------------------------------------===//
     28   //
     29   // createGlobalsModRefPass - This pass provides alias and mod/ref info for
     30   // global values that do not have their addresses taken.
     31   //
     32   Pass *createGlobalsModRefPass();
     33 
     34   //===--------------------------------------------------------------------===//
     35   //
     36   // createAliasDebugger - This pass helps debug clients of AA
     37   //
     38   Pass *createAliasDebugger();
     39 
     40   //===--------------------------------------------------------------------===//
     41   //
     42   // createAliasAnalysisCounterPass - This pass counts alias queries and how the
     43   // alias analysis implementation responds.
     44   //
     45   ModulePass *createAliasAnalysisCounterPass();
     46 
     47   //===--------------------------------------------------------------------===//
     48   //
     49   // createAAEvalPass - This pass implements a simple N^2 alias analysis
     50   // accuracy evaluator.
     51   //
     52   FunctionPass *createAAEvalPass();
     53 
     54   //===--------------------------------------------------------------------===//
     55   //
     56   // createNoAAPass - This pass implements a "I don't know" alias analysis.
     57   //
     58   ImmutablePass *createNoAAPass();
     59 
     60   //===--------------------------------------------------------------------===//
     61   //
     62   // createBasicAliasAnalysisPass - This pass implements the stateless alias
     63   // analysis.
     64   //
     65   ImmutablePass *createBasicAliasAnalysisPass();
     66 
     67   //===--------------------------------------------------------------------===//
     68   //
     69   /// createLibCallAliasAnalysisPass - Create an alias analysis pass that knows
     70   /// about the semantics of a set of libcalls specified by LCI.  The newly
     71   /// constructed pass takes ownership of the pointer that is provided.
     72   ///
     73   FunctionPass *createLibCallAliasAnalysisPass(LibCallInfo *LCI);
     74 
     75   //===--------------------------------------------------------------------===//
     76   //
     77   // createScalarEvolutionAliasAnalysisPass - This pass implements a simple
     78   // alias analysis using ScalarEvolution queries.
     79   //
     80   FunctionPass *createScalarEvolutionAliasAnalysisPass();
     81 
     82   //===--------------------------------------------------------------------===//
     83   //
     84   // createTypeBasedAliasAnalysisPass - This pass implements metadata-based
     85   // type-based alias analysis.
     86   //
     87   ImmutablePass *createTypeBasedAliasAnalysisPass();
     88 
     89   //===--------------------------------------------------------------------===//
     90   //
     91   // createObjCARCAliasAnalysisPass - This pass implements ObjC-ARC-based
     92   // alias analysis.
     93   //
     94   ImmutablePass *createObjCARCAliasAnalysisPass();
     95 
     96   //===--------------------------------------------------------------------===//
     97   //
     98   // createProfileLoaderPass - This pass loads information from a profile dump
     99   // file.
    100   //
    101   ModulePass *createProfileLoaderPass();
    102   extern char &ProfileLoaderPassID;
    103 
    104   //===--------------------------------------------------------------------===//
    105   //
    106   // createNoProfileInfoPass - This pass implements the default "no profile".
    107   //
    108   ImmutablePass *createNoProfileInfoPass();
    109 
    110   //===--------------------------------------------------------------------===//
    111   //
    112   // createProfileEstimatorPass - This pass estimates profiling information
    113   // instead of loading it from a previous run.
    114   //
    115   FunctionPass *createProfileEstimatorPass();
    116   extern char &ProfileEstimatorPassID;
    117 
    118   //===--------------------------------------------------------------------===//
    119   //
    120   // createProfileVerifierPass - This pass verifies profiling information.
    121   //
    122   FunctionPass *createProfileVerifierPass();
    123 
    124   //===--------------------------------------------------------------------===//
    125   //
    126   // createPathProfileLoaderPass - This pass loads information from a path
    127   // profile dump file.
    128   //
    129   ModulePass *createPathProfileLoaderPass();
    130   extern char &PathProfileLoaderPassID;
    131 
    132   //===--------------------------------------------------------------------===//
    133   //
    134   // createNoPathProfileInfoPass - This pass implements the default
    135   // "no path profile".
    136   //
    137   ImmutablePass *createNoPathProfileInfoPass();
    138 
    139   //===--------------------------------------------------------------------===//
    140   //
    141   // createPathProfileVerifierPass - This pass verifies path profiling
    142   // information.
    143   //
    144   ModulePass *createPathProfileVerifierPass();
    145 
    146   //===--------------------------------------------------------------------===//
    147   //
    148   // createDSAAPass - This pass implements simple context sensitive alias
    149   // analysis.
    150   //
    151   ModulePass *createDSAAPass();
    152 
    153   //===--------------------------------------------------------------------===//
    154   //
    155   // createDSOptPass - This pass uses DSA to do a series of simple
    156   // optimizations.
    157   //
    158   ModulePass *createDSOptPass();
    159 
    160   //===--------------------------------------------------------------------===//
    161   //
    162   // createSteensgaardPass - This pass uses the data structure graphs to do a
    163   // simple context insensitive alias analysis.
    164   //
    165   ModulePass *createSteensgaardPass();
    166 
    167   //===--------------------------------------------------------------------===//
    168   //
    169   /// createLazyValueInfoPass - This creates an instance of the LazyValueInfo
    170   /// pass.
    171   FunctionPass *createLazyValueInfoPass();
    172 
    173   //===--------------------------------------------------------------------===//
    174   //
    175   // createLoopDependenceAnalysisPass - This creates an instance of the
    176   // LoopDependenceAnalysis pass.
    177   //
    178   LoopPass *createLoopDependenceAnalysisPass();
    179 
    180   // Minor pass prototypes, allowing us to expose them through bugpoint and
    181   // analyze.
    182   FunctionPass *createInstCountPass();
    183 
    184   // print debug info intrinsics in human readable form
    185   FunctionPass *createDbgInfoPrinterPass();
    186 
    187   //===--------------------------------------------------------------------===//
    188   //
    189   // createRegionInfoPass - This pass finds all single entry single exit regions
    190   // in a function and builds the region hierarchy.
    191   //
    192   FunctionPass *createRegionInfoPass();
    193 
    194   // Print module-level debug info metadata in human-readable form.
    195   ModulePass *createModuleDebugInfoPrinterPass();
    196 
    197   //===--------------------------------------------------------------------===//
    198   //
    199   // createMemDepPrinter - This pass exhaustively collects all memdep
    200   // information and prints it with -analyze.
    201   //
    202   FunctionPass *createMemDepPrinter();
    203 }
    204 
    205 #endif
    206