144
|
1 /* for mc-codegen.c */
|
61
|
2
|
221
|
3 extern int use; /* generated value will be used in gexpr */
|
327
|
4 extern char *init_src;
|
|
5 extern int size_of_int;
|
|
6 extern int size_of_short;
|
|
7 extern int size_of_float;
|
|
8 extern int size_of_double;
|
|
9 extern int size_of_longlong;
|
|
10 extern int bit_of_byte;
|
|
11 extern int endian;
|
83
|
12
|
221
|
13 #define USE_CREG (-1)
|
320
|
14 #define ASM_INPUT 1
|
|
15 #define ASM_OUTPUT 2
|
|
16 #define ASM_USED 3
|
|
17 #define MAX_ASM_REG 30
|
61
|
18
|
327
|
19 /* used by mc-parse */
|
104
|
20
|
331
|
21
|
|
22 extern NMTBL * def(NMTBL *n);
|
|
23 extern int arg_reorder(int arg,int new_arg);
|
|
24 extern int assign_data(int e, int t, NMTBL *n,int offset);
|
|
25 extern int assign_expr(int e1,int e2,int t);
|
|
26 extern int assign_expr0(int e1,int e2,int t,int type0);
|
|
27 extern int assop(int e1,int e2,int op,int t,int no_float);
|
|
28 extern int backdef(void);
|
|
29 extern int binop(int op, int e1, int e2, int t1, int t2);
|
|
30 extern int cexpr(int e);
|
|
31 extern int cond(int t,int e1,int e2,int e3);
|
|
32 extern int correct_type(int e,int t);
|
|
33 extern int csvalue();
|
|
34 extern int function_type(int e1,int *dots);
|
|
35 extern int gexpr(int e1,int use0);
|
|
36 extern int indop(int e);
|
|
37 extern int integral(int t);
|
|
38 extern int new_lvar(int size);
|
|
39 extern int new_lvar0(int sz);
|
327
|
40 extern int rvalue(int e);
|
|
41 extern int rvalue_t(int e,int t);
|
331
|
42 extern int search_struct_type(int type,char *name,int *dsp);
|
|
43 extern int strop(int e,int ind);
|
137
|
44 extern void arg_register(NMTBL *fnptr);
|
331
|
45 extern void bexpr(int e1, char cond, int l1);
|
|
46 extern void bexpr_u(int e1, char cond, int l1);
|
327
|
47 extern void checkret(void);
|
|
48 extern void closing();
|
|
49 extern void cmpdimm(int e, int csreg,int label,int cond);
|
331
|
50 extern void codegen_decl_init(); /* called before each declaration */
|
327
|
51 extern void codegen_init(); /* called only once */
|
|
52 extern void codegen_reinit(); /* called for each file */
|
328
|
53 extern void data_closing(NMTBL *n);
|
327
|
54 extern void def_label(int cslabel, int dlabel);
|
|
55 extern void emit_init_vars(void);
|
331
|
56 extern void fcheck(NMTBL *n);
|
327
|
57 extern void fdecl_struct(int fntype);
|
|
58 extern void free_lvar(int disp);
|
|
59 extern void gen_code_enter(char *name);
|
|
60 extern void gen_code_enter1(int args);
|
|
61 extern void gen_code_leave(char *name);
|
|
62 extern void gen_enter(char *name);
|
|
63 extern void gen_enter1();
|
331
|
64 extern void gen_jmp(int l);
|
363
|
65 extern void gen_indirect_goto(int e1);
|
327
|
66 extern void gen_leave(int control, char *name);
|
331
|
67 extern void init_free_lvar_list();
|
|
68 extern void lcheck(int e);
|
|
69 extern void opening(char *filename);
|
|
70 extern void parallel_rassign(int assigns);
|
|
71 extern void replace_return_struct(int func,int left);
|
327
|
72 extern void ret(void);
|
|
73
|
|
74 /* used by mc-cod-* */
|
|
75
|
|
76 extern int assign_expr0(int e1,int e2,int t,int type0) ;
|
61
|
77 extern void b_expr(int e1, char cond, int l1,int err);
|
327
|
78 extern int contains_p(int e,int (*p)(int));
|
61
|
79 extern void fwddef(int l);
|
327
|
80 extern int fwdlabel(void);
|
|
81 extern int g_expr(int e1);
|
|
82 extern int g_expr0(int e1);
|
|
83 extern int g_expr_u(int e1);
|
98
|
84 extern int is_code(NMTBL *fnptr);
|
|
85 extern int is_function(NMTBL *fnptr);
|
327
|
86 extern int scalar(int t);
|
336
|
87 extern int make_mask(int from,int to);
|
|
88
|
341
|
89 extern void init_ptr_cache();
|
|
90 extern void clear_ptr_cache_reg(int r);
|
|
91 extern int last_ptr_cache();
|
|
92 extern void clear_ptr_cache() ;
|
|
93 extern int get_ptr_cache(NMTBL *nptr);
|
61
|
94
|
366
|
95 extern int ilog(int i);
|
|
96
|
61
|
97 /* end */
|