properly mark symbols in the public API to be exported. This allows us to use -fvisib...
[libfirm] / include / libfirm / pseudo_irg.h
1 /*
2  * Copyright (C) 1995-2008 University of Karlsruhe.  All right reserved.
3  *
4  * This file is part of libFirm.
5  *
6  * This file may be distributed and/or modified under the terms of the
7  * GNU General Public License version 2 as published by the Free Software
8  * Foundation and appearing in the file LICENSE.GPL included in the
9  * packaging of this file.
10  *
11  * Licensees holding valid libFirm Professional Edition licenses may use
12  * this file in accordance with the libFirm Commercial License.
13  * Agreement provided with the Software.
14  *
15  * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
16  * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR
17  * PURPOSE.
18  */
19
20 /**
21  * @file
22  * @brief    interface to pseudo irgs
23  * @author   Goetz Lindenmaier, Boris Boesler
24  * @date     Oktober 2004
25  * @version  $Id$
26  */
27 #ifndef FIRM_IR_PSEUDO_IRG_H
28 #define FIRM_IR_PSEUDO_IRG_H
29
30 #include "firm_types.h"
31
32 #include "begin.h"
33
34 /** Create a new ir graph to build a pseudo representation of a procedure.
35  *
36  *  The pseudo representation can only be used for analyses.  It may not be
37  *  optimized.  Pseudo graphs are kept in a separate graph list in irprog.
38  */
39 FIRM_DLL ir_graph *new_pseudo_ir_graph(ir_entity *ent, int n_loc);
40
41 /** Returns non-zero ir ir_graph is pseudo graph.
42  *  Is irg a pseudo graph for analysis? */
43 FIRM_DLL int is_pseudo_ir_graph(ir_graph *irg);
44
45 /** Returns the number of pseudo graphs in the program. */
46 FIRM_DLL int get_irp_n_pseudo_irgs(void);
47
48 /** Add a graph as pseudo irg */
49 FIRM_DLL void add_irp_pseudo_irg(ir_graph *irg);
50
51 /** Returns the pos'th  pseudo graph in the program. */
52 FIRM_DLL ir_graph *get_irp_pseudo_irg(int pos);
53
54 /** If set, get_irp_n_irgs() and get_irp_irg() behave as if all pseudo
55     graphs are in the irg list. If not set, get_entity_irg() returns
56     NULL if the entity refers to a pseudo irg. */
57 FIRM_DLL void set_visit_pseudo_irgs(int x);
58 FIRM_DLL int  get_visit_pseudo_irgs(void);
59
60 #include "end.h"
61
62 #endif