bescripts: Remove unused execution unit specification.
[libfirm] / ir / be / beirgmod.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       Backend IRG modification routines.
23  * @author      Sebastian Hack, Daniel Grund, Matthias Braun, Christian Wuerdig
24  * @date        04.05.2005
25  *
26  * This file contains the following IRG modifications for be routines:
27  * - insertion of Perm nodes
28  * - empty block elimination
29  * - a simple dead node elimination (set inputs of unreachable nodes to BAD)
30  */
31 #ifndef FIRM_BE_BEIRGMOD_H
32 #define FIRM_BE_BEIRGMOD_H
33
34 #include "be_types.h"
35 #include "firm_types.h"
36
37 /**
38  * Insert a Perm which permutes all (non-ignore) live values of a given register class
39  * before a certain instruction.
40  * @param lv        Liveness Information.
41  * @param irn       The node to insert the Perm before.
42  * @return          The Perm or NULL if nothing was live before @p irn.
43  */
44 ir_node *insert_Perm_before(ir_graph *irg, const arch_register_class_t *cls,
45                                                    ir_node *irn);
46
47 /**
48  * Removes basic blocks that only contain a jump instruction
49  * (this will potentially create critical edges).
50  *
51  * @param irg  the graph that will be changed
52  *
53  * @return non-zero if the graph was changed, zero else
54  */
55 int be_remove_empty_blocks(ir_graph *irg);
56
57 /**
58  * Removes dead nodes from schedule
59  * @param irg  the graph
60  */
61 void be_remove_dead_nodes_from_schedule(ir_graph *irg);
62
63 #endif