466cb4446c2ea9bec33036b327ba2592f619324a
[oota-llvm.git] / include / llvm / Transforms / IPO.h
1 //===- llvm/Transforms/CleanupGCCOutput.h - Cleanup GCC Output ---*- C++ -*--=//
2 //
3 // These passes are used to cleanup the output of GCC.  GCC's output is
4 // unneccessarily gross for a couple of reasons. This pass does the following
5 // things to try to clean it up:
6 //
7 // * Eliminate names for GCC types that we know can't be needed by the user.
8 // * Eliminate names for types that are unused in the entire translation unit
9 // * Fix various problems that we might have in PHI nodes and casts
10 // * Link uses of 'void %foo(...)' to 'void %foo(sometypes)'
11 //
12 // Note:  This code produces dead declarations, it is a good idea to run DCE
13 //        after this pass.
14 //
15 //===----------------------------------------------------------------------===//
16
17 #ifndef LLVM_TRANSFORMS_CLEANUPGCCOUTPUT_H
18 #define LLVM_TRANSFORMS_CLEANUPGCCOUTPUT_H
19
20 class Pass;
21
22 // CleanupGCCOutputPass - Perform all of the function body transformations.
23 //
24 Pass *createCleanupGCCOutputPass();
25
26
27 // FunctionResolvingPass - Go over the functions that are in the module and
28 // look for functions that have the same name.  More often than not, there will
29 // be things like:
30 //    void "foo"(...)
31 //    void "foo"(int, int)
32 // because of the way things are declared in C.  If this is the case, patch
33 // things up.
34 //
35 // This is an interprocedural pass.
36 //
37 Pass *createFunctionResolvingPass();
38
39 #endif