3 * File name: ir/ir/iropt.h
4 * Purpose: iropt --- optimizations of an ir node.
5 * Author: Martin Trapp, Christian Schaefer
6 * Modified by: Goetz Lindenmaier
9 * Copyright: (c) 1998-2003 Universität Karlsruhe
10 * Licence: This file protected by GPL - GNU GENERAL PUBLIC LICENSE.
16 * Declarations for optimizations of an ir node.
18 * @author Martin Trapp, Christian Schaefer
29 /** If the expression referenced can be evaluated statically
30 * computed_value returns a tarval representing the result.
31 * Else returns tarval_bad. */
32 tarval *computed_value (ir_node *n);
34 /** Applies all optimizations to n that are expressible as a pattern
35 * in Firm, i.e., they need not a walk of the graph.
36 * Returns a better node for n. Does not free n -- other nodes could
39 * An equivalent optimization is applied in the constructors defined in
40 * ircons.ch. There n is freed if a better node could be found.
42 ir_node *optimize_in_place (ir_node *n);
44 # endif /* _IROPT_H_ */