5 * File name: ir/external/pseudo_irg.h
6 * Purpose: interface to pseudo irgs
7 * Author: G"otz Lindenmaier
8 * Modified by: Boris Boesler
11 * Copyright: (c) 1999-2004 Universität Karlsruhe
12 * Licence: This file is protected by GPL - GNU GENERAL PUBLIC LICENSE.
15 #ifndef _FIRM_IR_PSEUDO_IRG_H_
16 #define _FIRM_IR_PSEUDO_IRG_H_
18 #include "firm_types.h"
20 /** Create a new ir graph to build a pseudo representation of a procedure.
22 * The pseudo representation can only be used for analyses. It may not be
23 * optimized. Pseudo graphs are kept in a separate graph list in irprog.
25 ir_graph *new_pseudo_ir_graph(ir_entity *ent, int n_loc);
27 /** Returns non-zero ir ir_graph is pseudo graph.
28 * Is irg a pseudo graph for analysis? */
29 int is_pseudo_ir_graph(ir_graph *irg);
31 /** Returns the number of pseudo graphs in the program. */
32 int get_irp_n_pseudo_irgs(void);
34 /** Returns the pos'th pseudo graph in the program. */
35 ir_graph *get_irp_pseudo_irg(int pos);
38 /** If set, get_irp_n_irgs() and get_irp_irg() behave as if all pseudo
39 graphs are in the irg list. If not set, get_entity_irg() returns
40 NULL if the entity refers to a pseudo irg. */
41 void set_visit_pseudo_irgs(int x);
42 int get_visit_pseudo_irgs(void);
44 #endif /* _FIRM_IR_PSEUDO_IRG_H_ */