added nolea option to switch of LEA optimization
[libfirm] / ir / be / be.h
1
2 #ifndef _BE_MAIN_H
3 #define _BE_MAIN_H
4
5 #include <stdio.h>
6 #include "dbginfo.h"
7
8 /**
9  * Register the Firm backend command line options.
10  */
11 void be_opt_register(void);
12
13 /**
14  * Parse one backend argument.
15  */
16 int be_parse_arg(const char *arg);
17
18 /**
19  * Initialize the Firm backend. Must be run BEFORE init_firm()!
20  */
21 void be_init(void);
22
23 /**
24  * Main interface to the frontend.
25  */
26 void be_main(FILE *file_handle);
27
28 /** The type of the debug info retriever function. */
29 typedef const char *(*retrieve_dbg_func)(const dbg_info *dbg, unsigned *line);
30
31 /**
32  * Sets a debug info retriever.
33  *
34  * @param func   the debug retriever function.
35  */
36 void be_set_debug_retrieve(retrieve_dbg_func func);
37
38 /**
39  * Retrieve the debug info.
40  */
41 const char *be_retrieve_dbg_info(const dbg_info *dbg, unsigned *line);
42
43 typedef struct _be_main_env_t be_main_env_t;
44 typedef struct _be_irg_t be_irg_t;
45 typedef struct _be_options_t be_options_t;
46
47 #endif /* _BE_MAIN_H */