1 #ifndef _BEARCH_TEMPLATE_T_H_
2 #define _BEARCH_TEMPLATE_T_H_
5 #include "bearch_TEMPLATE.h"
6 #include "TEMPLATE_nodes_attr.h"
8 #include "../beemitter.h"
11 typedef struct _TEMPLATE_isa_t TEMPLATE_isa_t;
13 typedef struct _TEMPLATE_code_gen_t {
14 const arch_code_generator_if_t *impl; /**< implementation */
15 ir_graph *irg; /**< current irg */
16 const arch_env_t *arch_env; /**< the arch env */
17 set *reg_set; /**< set to memorize registers for FIRM nodes (e.g. phi) */
18 TEMPLATE_isa_t *isa; /**< the isa instance */
19 const be_irg_t *birg; /**< The be-irg (contains additional information about the irg) */
20 DEBUG_ONLY(firm_dbg_module_t *mod;) /**< debugging module */
21 } TEMPLATE_code_gen_t;
23 struct _TEMPLATE_isa_t {
24 arch_isa_t arch_isa; /**< must be derived from arch_isa */
25 be_emit_env_t emit; /**< emit datastructure */
29 typedef struct _TEMPLATE_irn_ops_t {
30 const arch_irn_ops_if_t *impl;
31 TEMPLATE_code_gen_t *cg;
35 /* this is a struct to minimize the number of parameters
36 for transformation walker */
37 typedef struct _TEMPLATE_transform_env_t {
38 dbg_info *dbg; /**< The node debug info */
39 ir_graph *irg; /**< The irg, the node should be created in */
40 ir_node *block; /**< The block, the node should belong to */
41 ir_node *irn; /**< The irn, to be transformed */
42 ir_mode *mode; /**< The mode of the irn */
43 DEBUG_ONLY(firm_dbg_module_t *mod;) /**< The firm debugger */
44 } TEMPLATE_transform_env_t;
47 #endif /* _BEARCH_TEMPLATE_T_H_ */