[NPM] Port strip nonlinetable debuginfo pass to the new pass manager
[lldb.git] / llvm / lib / Passes / PassRegistry.def
1 //===- PassRegistry.def - Registry of passes --------------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file is used as the registry of passes that are part of the core LLVM
10 // libraries. This file describes both transformation passes and analyses
11 // Analyses are registered while transformation passes have names registered
12 // that can be used when providing a textual pass pipeline.
13 //
14 //===----------------------------------------------------------------------===//
15
16 // NOTE: NO INCLUDE GUARD DESIRED!
17
18 #ifndef MODULE_ANALYSIS
19 #define MODULE_ANALYSIS(NAME, CREATE_PASS)
20 #endif
21 MODULE_ANALYSIS("callgraph", CallGraphAnalysis())
22 MODULE_ANALYSIS("lcg", LazyCallGraphAnalysis())
23 MODULE_ANALYSIS("module-summary", ModuleSummaryIndexAnalysis())
24 MODULE_ANALYSIS("no-op-module", NoOpModuleAnalysis())
25 MODULE_ANALYSIS("profile-summary", ProfileSummaryAnalysis())
26 MODULE_ANALYSIS("stack-safety", StackSafetyGlobalAnalysis())
27 MODULE_ANALYSIS("verify", VerifierAnalysis())
28 MODULE_ANALYSIS("pass-instrumentation", PassInstrumentationAnalysis(PIC))
29 MODULE_ANALYSIS("asan-globals-md", ASanGlobalsMetadataAnalysis())
30 MODULE_ANALYSIS("inline-advisor", InlineAdvisorAnalysis())
31 MODULE_ANALYSIS("ir-similarity", IRSimilarityAnalysis())
32
33 #ifndef MODULE_ALIAS_ANALYSIS
34 #define MODULE_ALIAS_ANALYSIS(NAME, CREATE_PASS)                               \
35   MODULE_ANALYSIS(NAME, CREATE_PASS)
36 #endif
37 MODULE_ALIAS_ANALYSIS("globals-aa", GlobalsAA())
38 #undef MODULE_ALIAS_ANALYSIS
39 #undef MODULE_ANALYSIS
40
41 #ifndef MODULE_PASS
42 #define MODULE_PASS(NAME, CREATE_PASS)
43 #endif
44 MODULE_PASS("always-inline", AlwaysInlinerPass())
45 MODULE_PASS("attributor", AttributorPass())
46 MODULE_PASS("called-value-propagation", CalledValuePropagationPass())
47 MODULE_PASS("canonicalize-aliases", CanonicalizeAliasesPass())
48 MODULE_PASS("cg-profile", CGProfilePass())
49 MODULE_PASS("constmerge", ConstantMergePass())
50 MODULE_PASS("cross-dso-cfi", CrossDSOCFIPass())
51 MODULE_PASS("deadargelim", DeadArgumentEliminationPass())
52 MODULE_PASS("elim-avail-extern", EliminateAvailableExternallyPass())
53 MODULE_PASS("forceattrs", ForceFunctionAttrsPass())
54 MODULE_PASS("function-import", FunctionImportPass())
55 MODULE_PASS("globaldce", GlobalDCEPass())
56 MODULE_PASS("globalopt", GlobalOptPass())
57 MODULE_PASS("globalsplit", GlobalSplitPass())
58 MODULE_PASS("hotcoldsplit", HotColdSplittingPass())
59 MODULE_PASS("hwasan", HWAddressSanitizerPass(false, false))
60 MODULE_PASS("khwasan", HWAddressSanitizerPass(true, true))
61 MODULE_PASS("inferattrs", InferFunctionAttrsPass())
62 MODULE_PASS("inliner-wrapper", ModuleInlinerWrapperPass())
63 MODULE_PASS("insert-gcov-profiling", GCOVProfilerPass())
64 MODULE_PASS("instrorderfile", InstrOrderFilePass())
65 MODULE_PASS("instrprof", InstrProfiling())
66 MODULE_PASS("internalize", InternalizePass())
67 MODULE_PASS("invalidate<all>", InvalidateAllAnalysesPass())
68 MODULE_PASS("ipsccp", IPSCCPPass())
69 MODULE_PASS("print-ir-similarity", IRSimilarityAnalysisPrinterPass(dbgs()))
70 MODULE_PASS("lowertypetests", LowerTypeTestsPass())
71 MODULE_PASS("metarenamer", MetaRenamerPass())
72 MODULE_PASS("mergefunc", MergeFunctionsPass())
73 MODULE_PASS("name-anon-globals", NameAnonGlobalPass())
74 MODULE_PASS("no-op-module", NoOpModulePass())
75 MODULE_PASS("objc-arc", ObjCARCOptPass())
76 MODULE_PASS("objc-arc-contract", ObjCARCContractPass())
77 MODULE_PASS("partial-inliner", PartialInlinerPass())
78 MODULE_PASS("pgo-icall-prom", PGOIndirectCallPromotion())
79 MODULE_PASS("pgo-instr-gen", PGOInstrumentationGen())
80 MODULE_PASS("pgo-instr-use", PGOInstrumentationUse())
81 MODULE_PASS("print-profile-summary", ProfileSummaryPrinterPass(dbgs()))
82 MODULE_PASS("print-callgraph", CallGraphPrinterPass(dbgs()))
83 MODULE_PASS("print", PrintModulePass(dbgs()))
84 MODULE_PASS("print-lcg", LazyCallGraphPrinterPass(dbgs()))
85 MODULE_PASS("print-lcg-dot", LazyCallGraphDOTPrinterPass(dbgs()))
86 MODULE_PASS("print-stack-safety", StackSafetyGlobalPrinterPass(dbgs()))
87 MODULE_PASS("rewrite-statepoints-for-gc", RewriteStatepointsForGC())
88 MODULE_PASS("rewrite-symbols", RewriteSymbolPass())
89 MODULE_PASS("rpo-function-attrs", ReversePostOrderFunctionAttrsPass())
90 MODULE_PASS("sample-profile", SampleProfileLoaderPass())
91 MODULE_PASS("scc-oz-module-inliner",
92   buildInlinerPipeline(OptimizationLevel::Oz, ThinLTOPhase::None, DebugLogging))
93 MODULE_PASS("oz-module-optimizer",
94   buildModuleOptimizationPipeline(OptimizationLevel::Oz, DebugLogging, /*LTOPreLink*/false))
95 MODULE_PASS("strip", StripSymbolsPass())
96 MODULE_PASS("strip-dead-debug-info", StripDeadDebugInfoPass())
97 MODULE_PASS("strip-dead-prototypes", StripDeadPrototypesPass())
98 MODULE_PASS("strip-debug-declare", StripDebugDeclarePass())
99 MODULE_PASS("strip-nondebug", StripNonDebugSymbolsPass())
100 MODULE_PASS("strip-nonlinetable-debuginfo", StripNonLineTableDebugInfoPass())
101 MODULE_PASS("synthetic-counts-propagation", SyntheticCountsPropagation())
102 MODULE_PASS("wholeprogramdevirt", WholeProgramDevirtPass())
103 MODULE_PASS("verify", VerifierPass())
104 MODULE_PASS("dfsan", DataFlowSanitizerPass())
105 MODULE_PASS("asan-module", ModuleAddressSanitizerPass(/*CompileKernel=*/false, false, true, false))
106 MODULE_PASS("msan-module", MemorySanitizerPass({}))
107 MODULE_PASS("tsan-module", ThreadSanitizerPass())
108 MODULE_PASS("kasan-module", ModuleAddressSanitizerPass(/*CompileKernel=*/true, false, true, false))
109 MODULE_PASS("sancov-module", ModuleSanitizerCoveragePass())
110 MODULE_PASS("memprof-module", ModuleMemProfilerPass())
111 MODULE_PASS("poison-checking", PoisonCheckingPass())
112 #undef MODULE_PASS
113
114 #ifndef CGSCC_ANALYSIS
115 #define CGSCC_ANALYSIS(NAME, CREATE_PASS)
116 #endif
117 CGSCC_ANALYSIS("no-op-cgscc", NoOpCGSCCAnalysis())
118 CGSCC_ANALYSIS("fam-proxy", FunctionAnalysisManagerCGSCCProxy())
119 CGSCC_ANALYSIS("pass-instrumentation", PassInstrumentationAnalysis(PIC))
120 #undef CGSCC_ANALYSIS
121
122 #ifndef CGSCC_PASS
123 #define CGSCC_PASS(NAME, CREATE_PASS)
124 #endif
125 CGSCC_PASS("argpromotion", ArgumentPromotionPass())
126 CGSCC_PASS("invalidate<all>", InvalidateAllAnalysesPass())
127 CGSCC_PASS("function-attrs", PostOrderFunctionAttrsPass())
128 CGSCC_PASS("attributor-cgscc", AttributorCGSCCPass())
129 CGSCC_PASS("inline", InlinerPass())
130 CGSCC_PASS("openmpopt", OpenMPOptPass())
131 CGSCC_PASS("coro-split", CoroSplitPass())
132 CGSCC_PASS("no-op-cgscc", NoOpCGSCCPass())
133 #undef CGSCC_PASS
134
135 #ifndef FUNCTION_ANALYSIS
136 #define FUNCTION_ANALYSIS(NAME, CREATE_PASS)
137 #endif
138 FUNCTION_ANALYSIS("aa", AAManager())
139 FUNCTION_ANALYSIS("assumptions", AssumptionAnalysis())
140 FUNCTION_ANALYSIS("block-freq", BlockFrequencyAnalysis())
141 FUNCTION_ANALYSIS("branch-prob", BranchProbabilityAnalysis())
142 FUNCTION_ANALYSIS("domtree", DominatorTreeAnalysis())
143 FUNCTION_ANALYSIS("postdomtree", PostDominatorTreeAnalysis())
144 FUNCTION_ANALYSIS("demanded-bits", DemandedBitsAnalysis())
145 FUNCTION_ANALYSIS("domfrontier", DominanceFrontierAnalysis())
146 FUNCTION_ANALYSIS("func-properties", FunctionPropertiesAnalysis())
147 FUNCTION_ANALYSIS("loops", LoopAnalysis())
148 FUNCTION_ANALYSIS("lazy-value-info", LazyValueAnalysis())
149 FUNCTION_ANALYSIS("da", DependenceAnalysis())
150 FUNCTION_ANALYSIS("inliner-size-estimator", InlineSizeEstimatorAnalysis())
151 FUNCTION_ANALYSIS("memdep", MemoryDependenceAnalysis())
152 FUNCTION_ANALYSIS("memoryssa", MemorySSAAnalysis())
153 FUNCTION_ANALYSIS("phi-values", PhiValuesAnalysis())
154 FUNCTION_ANALYSIS("regions", RegionInfoAnalysis())
155 FUNCTION_ANALYSIS("no-op-function", NoOpFunctionAnalysis())
156 FUNCTION_ANALYSIS("opt-remark-emit", OptimizationRemarkEmitterAnalysis())
157 FUNCTION_ANALYSIS("scalar-evolution", ScalarEvolutionAnalysis())
158 FUNCTION_ANALYSIS("stack-safety-local", StackSafetyAnalysis())
159 FUNCTION_ANALYSIS("targetlibinfo", TargetLibraryAnalysis())
160 FUNCTION_ANALYSIS("targetir",
161                   TM ? TM->getTargetIRAnalysis() : TargetIRAnalysis())
162 FUNCTION_ANALYSIS("verify", VerifierAnalysis())
163 FUNCTION_ANALYSIS("pass-instrumentation", PassInstrumentationAnalysis(PIC))
164
165 #ifndef FUNCTION_ALIAS_ANALYSIS
166 #define FUNCTION_ALIAS_ANALYSIS(NAME, CREATE_PASS)                             \
167   FUNCTION_ANALYSIS(NAME, CREATE_PASS)
168 #endif
169 FUNCTION_ALIAS_ANALYSIS("basic-aa", BasicAA())
170 FUNCTION_ALIAS_ANALYSIS("cfl-anders-aa", CFLAndersAA())
171 FUNCTION_ALIAS_ANALYSIS("cfl-steens-aa", CFLSteensAA())
172 FUNCTION_ALIAS_ANALYSIS("objc-arc-aa", objcarc::ObjCARCAA())
173 FUNCTION_ALIAS_ANALYSIS("scev-aa", SCEVAA())
174 FUNCTION_ALIAS_ANALYSIS("scoped-noalias-aa", ScopedNoAliasAA())
175 FUNCTION_ALIAS_ANALYSIS("tbaa", TypeBasedAA())
176 #undef FUNCTION_ALIAS_ANALYSIS
177 #undef FUNCTION_ANALYSIS
178
179 #ifndef FUNCTION_PASS
180 #define FUNCTION_PASS(NAME, CREATE_PASS)
181 #endif
182 FUNCTION_PASS("aa-eval", AAEvaluator())
183 FUNCTION_PASS("adce", ADCEPass())
184 FUNCTION_PASS("add-discriminators", AddDiscriminatorsPass())
185 FUNCTION_PASS("aggressive-instcombine", AggressiveInstCombinePass())
186 FUNCTION_PASS("assume-builder", AssumeBuilderPass())
187 FUNCTION_PASS("assume-simplify", AssumeSimplifyPass())
188 FUNCTION_PASS("alignment-from-assumptions", AlignmentFromAssumptionsPass())
189 FUNCTION_PASS("bdce", BDCEPass())
190 FUNCTION_PASS("bounds-checking", BoundsCheckingPass())
191 FUNCTION_PASS("break-crit-edges", BreakCriticalEdgesPass())
192 FUNCTION_PASS("callsite-splitting", CallSiteSplittingPass())
193 FUNCTION_PASS("consthoist", ConstantHoistingPass())
194 FUNCTION_PASS("constraint-elimination", ConstraintEliminationPass())
195 FUNCTION_PASS("chr", ControlHeightReductionPass())
196 FUNCTION_PASS("coro-early", CoroEarlyPass())
197 FUNCTION_PASS("coro-elide", CoroElidePass())
198 FUNCTION_PASS("coro-cleanup", CoroCleanupPass())
199 FUNCTION_PASS("correlated-propagation", CorrelatedValuePropagationPass())
200 FUNCTION_PASS("dce", DCEPass())
201 FUNCTION_PASS("div-rem-pairs", DivRemPairsPass())
202 FUNCTION_PASS("dse", DSEPass())
203 FUNCTION_PASS("dot-cfg", CFGPrinterPass())
204 FUNCTION_PASS("dot-cfg-only", CFGOnlyPrinterPass())
205 FUNCTION_PASS("early-cse", EarlyCSEPass(/*UseMemorySSA=*/false))
206 FUNCTION_PASS("early-cse-memssa", EarlyCSEPass(/*UseMemorySSA=*/true))
207 FUNCTION_PASS("ee-instrument", EntryExitInstrumenterPass(/*PostInlining=*/false))
208 FUNCTION_PASS("make-guards-explicit", MakeGuardsExplicitPass())
209 FUNCTION_PASS("post-inline-ee-instrument", EntryExitInstrumenterPass(/*PostInlining=*/true))
210 FUNCTION_PASS("gvn-hoist", GVNHoistPass())
211 FUNCTION_PASS("gvn-sink", GVNSinkPass())
212 FUNCTION_PASS("helloworld", HelloWorldPass())
213 FUNCTION_PASS("instcombine", InstCombinePass())
214 FUNCTION_PASS("instcount", InstCountPass())
215 FUNCTION_PASS("instsimplify", InstSimplifyPass())
216 FUNCTION_PASS("invalidate<all>", InvalidateAllAnalysesPass())
217 FUNCTION_PASS("irce", IRCEPass())
218 FUNCTION_PASS("float2int", Float2IntPass())
219 FUNCTION_PASS("no-op-function", NoOpFunctionPass())
220 FUNCTION_PASS("libcalls-shrinkwrap", LibCallsShrinkWrapPass())
221 FUNCTION_PASS("lint", LintPass())
222 FUNCTION_PASS("inject-tli-mappings", InjectTLIMappings())
223 FUNCTION_PASS("loweratomic", LowerAtomicPass())
224 FUNCTION_PASS("lower-expect", LowerExpectIntrinsicPass())
225 FUNCTION_PASS("lower-guard-intrinsic", LowerGuardIntrinsicPass())
226 FUNCTION_PASS("lower-constant-intrinsics", LowerConstantIntrinsicsPass())
227 FUNCTION_PASS("lower-matrix-intrinsics", LowerMatrixIntrinsicsPass())
228 FUNCTION_PASS("lower-widenable-condition", LowerWidenableConditionPass())
229 FUNCTION_PASS("guard-widening", GuardWideningPass())
230 FUNCTION_PASS("load-store-vectorizer", LoadStoreVectorizerPass())
231 FUNCTION_PASS("loop-simplify", LoopSimplifyPass())
232 FUNCTION_PASS("loop-sink", LoopSinkPass())
233 FUNCTION_PASS("loop-unroll-and-jam", LoopUnrollAndJamPass())
234 FUNCTION_PASS("lowerinvoke", LowerInvokePass())
235 FUNCTION_PASS("lowerswitch", LowerSwitchPass())
236 FUNCTION_PASS("mem2reg", PromotePass())
237 FUNCTION_PASS("memcpyopt", MemCpyOptPass())
238 FUNCTION_PASS("mergeicmps", MergeICmpsPass())
239 FUNCTION_PASS("nary-reassociate", NaryReassociatePass())
240 FUNCTION_PASS("newgvn", NewGVNPass())
241 FUNCTION_PASS("jump-threading", JumpThreadingPass())
242 FUNCTION_PASS("partially-inline-libcalls", PartiallyInlineLibCallsPass())
243 FUNCTION_PASS("lcssa", LCSSAPass())
244 FUNCTION_PASS("loop-data-prefetch", LoopDataPrefetchPass())
245 FUNCTION_PASS("loop-load-elim", LoopLoadEliminationPass())
246 FUNCTION_PASS("loop-fusion", LoopFusePass())
247 FUNCTION_PASS("loop-distribute", LoopDistributePass())
248 FUNCTION_PASS("loop-versioning", LoopVersioningPass())
249 FUNCTION_PASS("pgo-memop-opt", PGOMemOPSizeOpt())
250 FUNCTION_PASS("print", PrintFunctionPass(dbgs()))
251 FUNCTION_PASS("print<assumptions>", AssumptionPrinterPass(dbgs()))
252 FUNCTION_PASS("print<block-freq>", BlockFrequencyPrinterPass(dbgs()))
253 FUNCTION_PASS("print<branch-prob>", BranchProbabilityPrinterPass(dbgs()))
254 FUNCTION_PASS("print<da>", DependenceAnalysisPrinterPass(dbgs()))
255 FUNCTION_PASS("print<domtree>", DominatorTreePrinterPass(dbgs()))
256 FUNCTION_PASS("print<postdomtree>", PostDominatorTreePrinterPass(dbgs()))
257 FUNCTION_PASS("print<delinearization>", DelinearizationPrinterPass(dbgs()))
258 FUNCTION_PASS("print<demanded-bits>", DemandedBitsPrinterPass(dbgs()))
259 FUNCTION_PASS("print<domfrontier>", DominanceFrontierPrinterPass(dbgs()))
260 FUNCTION_PASS("print<func-properties>", FunctionPropertiesPrinterPass(dbgs()))
261 FUNCTION_PASS("print<inline-cost>", InlineCostAnnotationPrinterPass(dbgs()))
262 FUNCTION_PASS("print<inliner-size-estimator>", 
263   InlineSizeEstimatorAnalysisPrinterPass(dbgs()))
264 FUNCTION_PASS("print<loops>", LoopPrinterPass(dbgs()))
265 FUNCTION_PASS("print<memoryssa>", MemorySSAPrinterPass(dbgs()))
266 FUNCTION_PASS("print<phi-values>", PhiValuesPrinterPass(dbgs()))
267 FUNCTION_PASS("print<regions>", RegionInfoPrinterPass(dbgs()))
268 FUNCTION_PASS("print<scalar-evolution>", ScalarEvolutionPrinterPass(dbgs()))
269 FUNCTION_PASS("print<stack-safety-local>", StackSafetyPrinterPass(dbgs()))
270 // TODO: rename to print<alias-sets> after NPM switch
271 FUNCTION_PASS("print-alias-sets", AliasSetsPrinterPass(dbgs()))
272 FUNCTION_PASS("print-predicateinfo", PredicateInfoPrinterPass(dbgs()))
273 FUNCTION_PASS("reassociate", ReassociatePass())
274 FUNCTION_PASS("scalarizer", ScalarizerPass())
275 FUNCTION_PASS("sccp", SCCPPass())
276 FUNCTION_PASS("simplifycfg", SimplifyCFGPass())
277 FUNCTION_PASS("sink", SinkingPass())
278 FUNCTION_PASS("slp-vectorizer", SLPVectorizerPass())
279 FUNCTION_PASS("speculative-execution", SpeculativeExecutionPass())
280 FUNCTION_PASS("spec-phis", SpeculateAroundPHIsPass())
281 FUNCTION_PASS("sroa", SROA())
282 FUNCTION_PASS("tailcallelim", TailCallElimPass())
283 FUNCTION_PASS("vector-combine", VectorCombinePass())
284 FUNCTION_PASS("verify", VerifierPass())
285 FUNCTION_PASS("verify<domtree>", DominatorTreeVerifierPass())
286 FUNCTION_PASS("verify<loops>", LoopVerifierPass())
287 FUNCTION_PASS("verify<memoryssa>", MemorySSAVerifierPass())
288 FUNCTION_PASS("verify<regions>", RegionInfoVerifierPass())
289 FUNCTION_PASS("verify<safepoint-ir>", SafepointIRVerifierPass())
290 FUNCTION_PASS("verify<scalar-evolution>", ScalarEvolutionVerifierPass())
291 FUNCTION_PASS("view-cfg", CFGViewerPass())
292 FUNCTION_PASS("view-cfg-only", CFGOnlyViewerPass())
293 FUNCTION_PASS("transform-warning", WarnMissedTransformationsPass())
294 FUNCTION_PASS("asan", AddressSanitizerPass(false, false, false))
295 FUNCTION_PASS("kasan", AddressSanitizerPass(true, false, false))
296 FUNCTION_PASS("msan", MemorySanitizerPass({}))
297 FUNCTION_PASS("kmsan", MemorySanitizerPass({0, false, /*Kernel=*/true}))
298 FUNCTION_PASS("tsan", ThreadSanitizerPass())
299 FUNCTION_PASS("memprof", MemProfilerPass())
300 #undef FUNCTION_PASS
301
302 #ifndef FUNCTION_PASS_WITH_PARAMS
303 #define FUNCTION_PASS_WITH_PARAMS(NAME, CREATE_PASS, PARSER)
304 #endif
305 FUNCTION_PASS_WITH_PARAMS("loop-unroll",
306                            [](LoopUnrollOptions Opts) {
307                              return LoopUnrollPass(Opts);
308                            },
309                            parseLoopUnrollOptions)
310 FUNCTION_PASS_WITH_PARAMS("msan",
311                            [](MemorySanitizerOptions Opts) {
312                              return MemorySanitizerPass(Opts);
313                            },
314                            parseMSanPassOptions)
315 FUNCTION_PASS_WITH_PARAMS("simplify-cfg",
316                            [](SimplifyCFGOptions Opts) {
317                              return SimplifyCFGPass(Opts);
318                            },
319                            parseSimplifyCFGOptions)
320 FUNCTION_PASS_WITH_PARAMS("loop-vectorize",
321                            [](LoopVectorizeOptions Opts) {
322                              return LoopVectorizePass(Opts);
323                            },
324                            parseLoopVectorizeOptions)
325 FUNCTION_PASS_WITH_PARAMS("mldst-motion",
326                            [](MergedLoadStoreMotionOptions Opts) {
327                              return MergedLoadStoreMotionPass(Opts);
328                            },
329                            parseMergedLoadStoreMotionOptions)
330 FUNCTION_PASS_WITH_PARAMS("gvn",
331                            [](GVNOptions Opts) {
332                              return GVN(Opts);
333                            },
334                            parseGVNOptions)
335 FUNCTION_PASS_WITH_PARAMS("print<stack-lifetime>",
336                            [](StackLifetime::LivenessType Type) {
337                              return StackLifetimePrinterPass(dbgs(), Type);
338                            },
339                            parseStackLifetimeOptions)
340 #undef FUNCTION_PASS_WITH_PARAMS
341
342 #ifndef LOOP_ANALYSIS
343 #define LOOP_ANALYSIS(NAME, CREATE_PASS)
344 #endif
345 LOOP_ANALYSIS("no-op-loop", NoOpLoopAnalysis())
346 LOOP_ANALYSIS("access-info", LoopAccessAnalysis())
347 LOOP_ANALYSIS("ddg", DDGAnalysis())
348 LOOP_ANALYSIS("iv-users", IVUsersAnalysis())
349 LOOP_ANALYSIS("pass-instrumentation", PassInstrumentationAnalysis(PIC))
350 #undef LOOP_ANALYSIS
351
352 #ifndef LOOP_PASS
353 #define LOOP_PASS(NAME, CREATE_PASS)
354 #endif
355 LOOP_PASS("canon-freeze", CanonicalizeFreezeInLoopsPass())
356 LOOP_PASS("invalidate<all>", InvalidateAllAnalysesPass())
357 LOOP_PASS("licm", LICMPass())
358 LOOP_PASS("loop-idiom", LoopIdiomRecognizePass())
359 LOOP_PASS("loop-instsimplify", LoopInstSimplifyPass())
360 LOOP_PASS("loop-rotate", LoopRotatePass())
361 LOOP_PASS("no-op-loop", NoOpLoopPass())
362 LOOP_PASS("print", PrintLoopPass(dbgs()))
363 LOOP_PASS("loop-deletion", LoopDeletionPass())
364 LOOP_PASS("loop-flatten", LoopFlattenPass())
365 LOOP_PASS("loop-simplifycfg", LoopSimplifyCFGPass())
366 LOOP_PASS("loop-reduce", LoopStrengthReducePass())
367 LOOP_PASS("indvars", IndVarSimplifyPass())
368 LOOP_PASS("loop-unroll-full", LoopFullUnrollPass())
369 LOOP_PASS("print-access-info", LoopAccessInfoPrinterPass(dbgs()))
370 LOOP_PASS("print<ddg>", DDGAnalysisPrinterPass(dbgs()))
371 LOOP_PASS("print<iv-users>", IVUsersPrinterPass(dbgs()))
372 LOOP_PASS("print<loopnest>", LoopNestPrinterPass(dbgs()))
373 LOOP_PASS("print<loop-cache-cost>", LoopCachePrinterPass(dbgs()))
374 LOOP_PASS("loop-predication", LoopPredicationPass())
375 LOOP_PASS("guard-widening", GuardWideningPass())
376 LOOP_PASS("simple-loop-unswitch", SimpleLoopUnswitchPass())
377 LOOP_PASS("loop-reroll", LoopRerollPass())
378 #undef LOOP_PASS
379
380 #ifndef LOOP_PASS_WITH_PARAMS
381 #define LOOP_PASS_WITH_PARAMS(NAME, CREATE_PASS, PARSER)
382 #endif
383 LOOP_PASS_WITH_PARAMS("unswitch",
384                            [](bool NonTrivial) {
385                              return SimpleLoopUnswitchPass(NonTrivial);
386                            },
387                            parseLoopUnswitchOptions)
388 #undef LOOP_PASS_WITH_PARAMS