1 | //===- llvm/Transforms/IPO.h - Interprocedural Transformations --*- 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 header file defines prototypes for accessor functions that expose passes |
10 | // in the IPO transformations library. |
11 | // |
12 | //===----------------------------------------------------------------------===// |
13 | |
14 | #ifndef LLVM_TRANSFORMS_IPO_H |
15 | #define LLVM_TRANSFORMS_IPO_H |
16 | |
17 | namespace llvm { |
18 | |
19 | class ModulePass; |
20 | class Pass; |
21 | class raw_ostream; |
22 | |
23 | //===----------------------------------------------------------------------===// |
24 | /// createDeadArgEliminationPass - This pass removes arguments from functions |
25 | /// which are not used by the body of the function. |
26 | /// |
27 | ModulePass *createDeadArgEliminationPass(); |
28 | |
29 | /// DeadArgHacking pass - Same as DAE, but delete arguments of external |
30 | /// functions as well. This is definitely not safe, and should only be used by |
31 | /// bugpoint. |
32 | ModulePass *createDeadArgHackingPass(); |
33 | |
34 | //===----------------------------------------------------------------------===// |
35 | // |
36 | /// createLoopExtractorPass - This pass extracts all natural loops from the |
37 | /// program into a function if it can. |
38 | /// |
39 | Pass *(); |
40 | |
41 | /// createSingleLoopExtractorPass - This pass extracts one natural loop from the |
42 | /// program into a function if it can. This is used by bugpoint. |
43 | /// |
44 | Pass *(); |
45 | |
46 | //===----------------------------------------------------------------------===// |
47 | /// createBarrierNoopPass - This pass is purely a module pass barrier in a pass |
48 | /// manager. |
49 | ModulePass *createBarrierNoopPass(); |
50 | |
51 | /// What to do with the summary when running passes that operate on it. |
52 | enum class PassSummaryAction { |
53 | None, ///< Do nothing. |
54 | Import, ///< Import information from summary. |
55 | Export, ///< Export information to summary. |
56 | }; |
57 | |
58 | } // End llvm namespace |
59 | |
60 | #endif |
61 | |