3 * File name: ir/common/firm_common.c
4 * Purpose: Stuff common to all firm modules.
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 * common firm declarations
18 * @author Martin Trapp, Christian Schaefer & Goetz Lindenmaier
21 # ifndef _FIRM_COMMON_H_
22 # define _FIRM_COMMON_H_
32 /** a list of firm kinds
33 @@@ not all datatypes are tagged yet. */
35 k_BAD = 0, /**< an invalid firm node */
36 k_entity, /**< an entity */
37 k_type, /**< a type */
38 k_ir_graph, /**< an ir graph */
39 k_ir_node, /**< an ir node */
40 k_ir_mode, /**< an ir mode */
41 k_ir_op, /**< an ir opcode */
42 k_tarval, /**< a tarval */
43 k_ir_loop, /**< a loop */
44 k_ir_compound_graph_path, /**< a compound graph path, see entity.h */
45 k_ir_max /**< maximum value -- illegal for firm nodes. */
49 * Returns the kind of a thing.
51 * @param firm_thing pointer representing a firm object
53 firm_kind get_kind(const void *firm_thing);
55 /** Returns the kind of a thing as a string. */
56 const char* print_firm_kind(void *firm_thing);
58 /** Print an identification of a firm thing. */
59 void firm_identify_thing(void *X);
61 # endif /*_FIRM_COMMON_H_ */