1 #ifndef _ARM_EMITTER_H_
2 #define _ARM_EMITTER_H_
4 #include "firm_types.h"
8 #include "../bearch_t.h"
10 #include "bearch_arm_t.h"
15 typedef struct _SymConstEntry {
16 unsigned label; /**< a label number for this label */
17 ir_node *symconst; /**< the node holding this label */
18 struct _SymConstEntry *next; /**< links all entries */
22 * The ARM emitter environment.
24 typedef struct _arm_emit_env_t {
25 FILE *out; /**< the output stream */
26 const arch_env_t *arch_env; /**< the architecture environment */
27 const arm_code_gen_t *cg; /**< the code generator object */
28 struct obstack obst; /**< an temporary store for SymConstEntries */
29 SymConstEntry *symbols; /**< list containing all SymConstEntries */
30 DEBUG_ONLY(firm_dbg_module_t *mod;)
33 const lc_arg_env_t *arm_get_arg_env(void);
35 void equalize_dest_src(FILE *F, ir_node *n);
37 int get_arm_reg_nr(ir_node *irn, int posi, int in_out);
38 const char *get_arm_in_reg_name(ir_node *irn, int pos);
40 void arm_gen_routine(FILE *F, ir_graph *irg, const arm_code_gen_t *cg);
45 typedef enum sections {
46 NO_SECTION, /**< no section selected yet. */
47 SECTION_TEXT, /**< text section */
48 SECTION_DATA, /**< data section */
49 SECTION_RODATA, /**< rodata section */
50 SECTION_COMMON, /**< common section */
54 * Switch to a new section
56 void arm_switch_section(FILE *f, sections sec);
58 #endif /* _ARM_EMITTER_H_ */