Mercurial > hg > CbC > CbC_llvm
annotate include/llvm/LinkAllPasses.h @ 97:b0dd3743370f
LLVM 3.8
author | Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp> |
---|---|
date | Wed, 14 Oct 2015 19:39:58 +0900 |
parents | 5e5d649e25d2 afa8332a0e37 |
children | 57be027de0f4 |
rev | line source |
---|---|
0 | 1 //===- llvm/LinkAllPasses.h ------------ Reference All Passes ---*- 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 pulls in all transformation and analysis passes for tools | |
11 // like opt and bugpoint that need this functionality. | |
12 // | |
13 //===----------------------------------------------------------------------===// | |
14 | |
15 #ifndef LLVM_LINKALLPASSES_H | |
16 #define LLVM_LINKALLPASSES_H | |
17 | |
95 | 18 #include "llvm/ADT/Statistic.h" |
0 | 19 #include "llvm/Analysis/AliasSetTracker.h" |
95 | 20 #include "llvm/Analysis/BasicAliasAnalysis.h" |
21 #include "llvm/Analysis/CFLAliasAnalysis.h" | |
0 | 22 #include "llvm/Analysis/CallPrinter.h" |
23 #include "llvm/Analysis/DomPrinter.h" | |
95 | 24 #include "llvm/Analysis/GlobalsModRef.h" |
0 | 25 #include "llvm/Analysis/IntervalPartition.h" |
26 #include "llvm/Analysis/Lint.h" | |
27 #include "llvm/Analysis/Passes.h" | |
28 #include "llvm/Analysis/PostDominators.h" | |
29 #include "llvm/Analysis/RegionPass.h" | |
30 #include "llvm/Analysis/RegionPrinter.h" | |
31 #include "llvm/Analysis/ScalarEvolution.h" | |
95 | 32 #include "llvm/Analysis/ScalarEvolutionAliasAnalysis.h" |
33 #include "llvm/Analysis/ScopedNoAliasAA.h" | |
34 #include "llvm/Analysis/TypeBasedAliasAnalysis.h" | |
0 | 35 #include "llvm/CodeGen/Passes.h" |
36 #include "llvm/IR/Function.h" | |
77 | 37 #include "llvm/IR/IRPrintingPasses.h" |
0 | 38 #include "llvm/Transforms/IPO.h" |
39 #include "llvm/Transforms/Instrumentation.h" | |
40 #include "llvm/Transforms/ObjCARC.h" | |
41 #include "llvm/Transforms/Scalar.h" | |
83 | 42 #include "llvm/Transforms/Utils/SymbolRewriter.h" |
0 | 43 #include "llvm/Transforms/Utils/UnifyFunctionExitNodes.h" |
44 #include "llvm/Transforms/Vectorize.h" | |
95 | 45 #include "llvm/Support/Valgrind.h" |
0 | 46 #include <cstdlib> |
47 | |
48 namespace { | |
49 struct ForcePassLinking { | |
50 ForcePassLinking() { | |
51 // We must reference the passes in such a way that compilers will not | |
52 // delete it all as dead code, even with whole program optimization, | |
53 // yet is effectively a NO-OP. As the compiler isn't smart enough | |
54 // to know that getenv() never returns -1, this will do the job. | |
55 if (std::getenv("bar") != (char*) -1) | |
56 return; | |
57 | |
58 (void) llvm::createAAEvalPass(); | |
59 (void) llvm::createAggressiveDCEPass(); | |
83 | 60 (void) llvm::createBitTrackingDCEPass(); |
0 | 61 (void) llvm::createArgumentPromotionPass(); |
77 | 62 (void) llvm::createAlignmentFromAssumptionsPass(); |
95 | 63 (void) llvm::createBasicAAWrapperPass(); |
64 (void) llvm::createSCEVAAWrapperPass(); | |
65 (void) llvm::createTypeBasedAAWrapperPass(); | |
66 (void) llvm::createScopedNoAliasAAWrapperPass(); | |
0 | 67 (void) llvm::createBoundsCheckingPass(); |
68 (void) llvm::createBreakCriticalEdgesPass(); | |
69 (void) llvm::createCallGraphPrinterPass(); | |
70 (void) llvm::createCallGraphViewerPass(); | |
71 (void) llvm::createCFGSimplificationPass(); | |
95 | 72 (void) llvm::createCFLAAWrapperPass(); |
0 | 73 (void) llvm::createStructurizeCFGPass(); |
74 (void) llvm::createConstantMergePass(); | |
75 (void) llvm::createConstantPropagationPass(); | |
76 (void) llvm::createCostModelAnalysisPass(); | |
77 (void) llvm::createDeadArgEliminationPass(); | |
78 (void) llvm::createDeadCodeEliminationPass(); | |
79 (void) llvm::createDeadInstEliminationPass(); | |
80 (void) llvm::createDeadStoreEliminationPass(); | |
81 (void) llvm::createDependenceAnalysisPass(); | |
95 | 82 (void) llvm::createDivergenceAnalysisPass(); |
0 | 83 (void) llvm::createDomOnlyPrinterPass(); |
84 (void) llvm::createDomPrinterPass(); | |
85 (void) llvm::createDomOnlyViewerPass(); | |
86 (void) llvm::createDomViewerPass(); | |
87 (void) llvm::createGCOVProfilerPass(); | |
83 | 88 (void) llvm::createInstrProfilingPass(); |
0 | 89 (void) llvm::createFunctionInliningPass(); |
90 (void) llvm::createAlwaysInlinerPass(); | |
91 (void) llvm::createGlobalDCEPass(); | |
92 (void) llvm::createGlobalOptimizerPass(); | |
95 | 93 (void) llvm::createGlobalsAAWrapperPass(); |
0 | 94 (void) llvm::createIPConstantPropagationPass(); |
95 (void) llvm::createIPSCCPPass(); | |
83 | 96 (void) llvm::createInductiveRangeCheckEliminationPass(); |
0 | 97 (void) llvm::createIndVarSimplifyPass(); |
98 (void) llvm::createInstructionCombiningPass(); | |
99 (void) llvm::createInternalizePass(); | |
100 (void) llvm::createLCSSAPass(); | |
101 (void) llvm::createLICMPass(); | |
102 (void) llvm::createLazyValueInfoPass(); | |
103 (void) llvm::createLoopExtractorPass(); | |
95 | 104 (void) llvm::createLoopInterchangePass(); |
0 | 105 (void) llvm::createLoopSimplifyPass(); |
106 (void) llvm::createLoopStrengthReducePass(); | |
107 (void) llvm::createLoopRerollPass(); | |
108 (void) llvm::createLoopUnrollPass(); | |
109 (void) llvm::createLoopUnswitchPass(); | |
110 (void) llvm::createLoopIdiomPass(); | |
111 (void) llvm::createLoopRotatePass(); | |
112 (void) llvm::createLowerExpectIntrinsicPass(); | |
113 (void) llvm::createLowerInvokePass(); | |
114 (void) llvm::createLowerSwitchPass(); | |
95 | 115 (void) llvm::createNaryReassociatePass(); |
116 (void) llvm::createObjCARCAAWrapperPass(); | |
0 | 117 (void) llvm::createObjCARCAPElimPass(); |
118 (void) llvm::createObjCARCExpandPass(); | |
119 (void) llvm::createObjCARCContractPass(); | |
120 (void) llvm::createObjCARCOptPass(); | |
83 | 121 (void) llvm::createPAEvalPass(); |
0 | 122 (void) llvm::createPromoteMemoryToRegisterPass(); |
123 (void) llvm::createDemoteRegisterToMemoryPass(); | |
124 (void) llvm::createPruneEHPass(); | |
125 (void) llvm::createPostDomOnlyPrinterPass(); | |
126 (void) llvm::createPostDomPrinterPass(); | |
127 (void) llvm::createPostDomOnlyViewerPass(); | |
128 (void) llvm::createPostDomViewerPass(); | |
129 (void) llvm::createReassociatePass(); | |
130 (void) llvm::createRegionInfoPass(); | |
131 (void) llvm::createRegionOnlyPrinterPass(); | |
132 (void) llvm::createRegionOnlyViewerPass(); | |
133 (void) llvm::createRegionPrinterPass(); | |
134 (void) llvm::createRegionViewerPass(); | |
135 (void) llvm::createSCCPPass(); | |
95 | 136 (void) llvm::createSafeStackPass(); |
0 | 137 (void) llvm::createScalarReplAggregatesPass(); |
138 (void) llvm::createSingleLoopExtractorPass(); | |
139 (void) llvm::createStripSymbolsPass(); | |
140 (void) llvm::createStripNonDebugSymbolsPass(); | |
141 (void) llvm::createStripDeadDebugInfoPass(); | |
142 (void) llvm::createStripDeadPrototypesPass(); | |
35
503e14e069e4
update to LLVM 3.5
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
33
diff
changeset
|
143 #ifndef noCbC |
503e14e069e4
update to LLVM 3.5
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
33
diff
changeset
|
144 (void) llvm::createTailCallEliminationPass(false); |
503e14e069e4
update to LLVM 3.5
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
33
diff
changeset
|
145 #else |
0 | 146 (void) llvm::createTailCallEliminationPass(); |
35
503e14e069e4
update to LLVM 3.5
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
33
diff
changeset
|
147 #endif |
0 | 148 (void) llvm::createJumpThreadingPass(); |
149 (void) llvm::createUnifyFunctionExitNodesPass(); | |
150 (void) llvm::createInstCountPass(); | |
77 | 151 (void) llvm::createConstantHoistingPass(); |
0 | 152 (void) llvm::createCodeGenPreparePass(); |
153 (void) llvm::createEarlyCSEPass(); | |
83 | 154 (void) llvm::createMergedLoadStoreMotionPass(); |
0 | 155 (void) llvm::createGVNPass(); |
156 (void) llvm::createMemCpyOptPass(); | |
157 (void) llvm::createLoopDeletionPass(); | |
158 (void) llvm::createPostDomTree(); | |
159 (void) llvm::createInstructionNamerPass(); | |
160 (void) llvm::createMetaRenamerPass(); | |
161 (void) llvm::createFunctionAttrsPass(); | |
162 (void) llvm::createMergeFunctionsPass(); | |
77 | 163 (void) llvm::createPrintModulePass(*(llvm::raw_ostream*)nullptr); |
164 (void) llvm::createPrintFunctionPass(*(llvm::raw_ostream*)nullptr); | |
165 (void) llvm::createPrintBasicBlockPass(*(llvm::raw_ostream*)nullptr); | |
0 | 166 (void) llvm::createModuleDebugInfoPrinterPass(); |
167 (void) llvm::createPartialInliningPass(); | |
168 (void) llvm::createLintPass(); | |
169 (void) llvm::createSinkingPass(); | |
170 (void) llvm::createLowerAtomicPass(); | |
171 (void) llvm::createCorrelatedValuePropagationPass(); | |
172 (void) llvm::createMemDepPrinter(); | |
173 (void) llvm::createInstructionSimplifierPass(); | |
174 (void) llvm::createLoopVectorizePass(); | |
175 (void) llvm::createSLPVectorizerPass(); | |
176 (void) llvm::createBBVectorizePass(); | |
177 (void) llvm::createPartiallyInlineLibCallsPass(); | |
33 | 178 (void) llvm::createScalarizerPass(); |
77 | 179 (void) llvm::createSeparateConstOffsetFromGEPPass(); |
95 | 180 (void) llvm::createSpeculativeExecutionPass(); |
83 | 181 (void) llvm::createRewriteSymbolsPass(); |
182 (void) llvm::createStraightLineStrengthReducePass(); | |
183 (void) llvm::createMemDerefPrinter(); | |
95 | 184 (void) llvm::createFloat2IntPass(); |
185 (void) llvm::createEliminateAvailableExternallyPass(); | |
0 | 186 |
187 (void)new llvm::IntervalPartition(); | |
95 | 188 (void)new llvm::ScalarEvolutionWrapperPass(); |
77 | 189 ((llvm::Function*)nullptr)->viewCFGOnly(); |
0 | 190 llvm::RGPassManager RGM; |
77 | 191 ((llvm::RegionPass*)nullptr)->runOnRegion((llvm::Region*)nullptr, RGM); |
192 llvm::AliasSetTracker X(*(llvm::AliasAnalysis*)nullptr); | |
83 | 193 X.add(nullptr, 0, llvm::AAMDNodes()); // for -print-alias-sets |
95 | 194 (void) llvm::AreStatisticsEnabled(); |
195 (void) llvm::sys::RunningOnValgrind(); | |
0 | 196 } |
197 } ForcePassLinking; // Force link by creating a global definition. | |
198 } | |
199 | |
200 #endif |